summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/unix/notbsd/linux/mod.rs8
-rw-r--r--src/unix/notbsd/mod.rs9
2 files changed, 8 insertions, 9 deletions
diff --git a/src/unix/notbsd/linux/mod.rs b/src/unix/notbsd/linux/mod.rs
index 3ead50d894..9141ff4160 100644
--- a/src/unix/notbsd/linux/mod.rs
+++ b/src/unix/notbsd/linux/mod.rs
@@ -462,6 +462,13 @@ pub const LOG_NFACILITIES: ::c_int = 24;
pub const SEM_FAILED: *mut ::sem_t = 0 as *mut sem_t;
+pub const RB_AUTOBOOT: ::c_int = 0x01234567;
+pub const RB_HALT_SYSTEM: ::c_int = 0xcdef0123;
+pub const RB_ENABLE_CAD: ::c_int = 0x89abcdef;
+pub const RB_DISABLE_CAD: ::c_int = 0;
+pub const RB_POWER_OFF: ::c_int = 0x4321fedc;
+pub const RB_SW_SUSPEND: ::c_int = 0xd000fce2;
+pub const RB_KEXEC: ::c_int = 0x45584543;
f! {
pub fn CPU_ZERO(cpuset: &mut cpu_set_t) -> () {
@@ -634,6 +641,7 @@ extern {
remote_iov: *const ::iovec,
riovcnt: ::c_ulong,
flags: ::c_ulong) -> isize;
+ pub fn reboot(how_to: ::c_int) -> ::c_int;
// Not available now on Android
pub fn mkfifoat(dirfd: ::c_int, pathname: *const ::c_char,
diff --git a/src/unix/notbsd/mod.rs b/src/unix/notbsd/mod.rs
index e9a9314146..f1add7f6ea 100644
--- a/src/unix/notbsd/mod.rs
+++ b/src/unix/notbsd/mod.rs
@@ -666,14 +666,6 @@ pub const PIPE_BUF: usize = 4096;
pub const SI_LOAD_SHIFT: ::c_uint = 16;
-pub const RB_AUTOBOOT: ::c_int = 0x01234567;
-pub const RB_HALT_SYSTEM: ::c_int = 0xcdef0123;
-pub const RB_ENABLE_CAD: ::c_int = 0x89abcdef;
-pub const RB_DISABLE_CAD: ::c_int = 0;
-pub const RB_POWER_OFF: ::c_int = 0x4321fedc;
-pub const RB_SW_SUSPEND: ::c_int = 0xd000fce2;
-pub const RB_KEXEC: ::c_int = 0x45584543;
-
f! {
pub fn FD_CLR(fd: ::c_int, set: *mut fd_set) -> () {
let fd = fd as usize;
@@ -868,7 +860,6 @@ extern {
linkpath: *const ::c_char) -> ::c_int;
pub fn unlinkat(dirfd: ::c_int, pathname: *const ::c_char,
flags: ::c_int) -> ::c_int;
- pub fn reboot(how_to: ::c_int) -> ::c_int;
}
cfg_if! {