Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Define FICLONE on mips and power. #3212

Merged
merged 1 commit into from
Apr 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 2 additions & 8 deletions src/unix/linux_like/linux/arch/generic/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,8 @@ cfg_if! {
pub const SO_DETACH_REUSEPORT_BPF: ::c_int = 68;
}
}
// pub const SO_PREFER_BUSY_POLL: ::c_int = 69;
// pub const SO_BUSY_POLL_BUDGET: ::c_int = 70;

cfg_if! {
if #[cfg(any(target_arch = "x86",
Expand All @@ -114,16 +116,8 @@ cfg_if! {
target_arch = "s390x"))] {
pub const FICLONE: ::c_ulong = 0x40049409;
pub const FICLONERANGE: ::c_ulong = 0x4020940D;
} else if #[cfg(any(target_arch = "mips",
target_arch = "mips64",
target_arch = "powerpc",
target_arch = "powerpc64"))] {
pub const FICLONE: ::c_ulong = 0x80049409;
pub const FICLONERANGE: ::c_ulong = 0x8020940D;
}
}
// pub const SO_PREFER_BUSY_POLL: ::c_int = 69;
// pub const SO_BUSY_POLL_BUDGET: ::c_int = 70;

// Defined in unix/linux_like/mod.rs
// pub const SCM_TIMESTAMP: ::c_int = SO_TIMESTAMP;
Expand Down
3 changes: 3 additions & 0 deletions src/unix/linux_like/linux/arch/mips/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,9 @@ pub const SO_TIMESTAMPING: ::c_int = 37;
// pub const SO_PREFER_BUSY_POLL: ::c_int = 69;
// pub const SO_BUSY_POLL_BUDGET: ::c_int = 70;

pub const FICLONE: ::c_ulong = 0x80049409;
pub const FICLONERANGE: ::c_ulong = 0x8020940D;

// Defined in unix/linux_like/mod.rs
// pub const SCM_TIMESTAMP: ::c_int = SO_TIMESTAMP;
pub const SCM_TIMESTAMPNS: ::c_int = SO_TIMESTAMPNS;
Expand Down
3 changes: 3 additions & 0 deletions src/unix/linux_like/linux/arch/powerpc/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,9 @@ pub const SO_BINDTOIFINDEX: ::c_int = 62;
// pub const SO_PREFER_BUSY_POLL: ::c_int = 69;
// pub const SO_BUSY_POLL_BUDGET: ::c_int = 70;

pub const FICLONE: ::c_ulong = 0x80049409;
pub const FICLONERANGE: ::c_ulong = 0x8020940D;

// Defined in unix/linux_like/mod.rs
// pub const SCM_TIMESTAMP: ::c_int = SO_TIMESTAMP;
pub const SCM_TIMESTAMPNS: ::c_int = SO_TIMESTAMPNS;
Expand Down