diff options
author | bors <bors@rust-lang.org> | 2022-01-17 03:06:28 +0000 |
---|---|---|
committer | bors <bors@rust-lang.org> | 2022-01-17 03:06:28 +0000 |
commit | df679e80756d9a71e9a7b0b298c0c45ba7b70083 (patch) | |
tree | 66dceef4bb6f578f189767c3c908a3418e9233f5 /src | |
parent | f0ba214ebb49706e0d68d694e3448771e70ed8ed (diff) | |
parent | 0a57541a7101bd58051b1d193e5a71981715bacb (diff) | |
download | rust-libc-df679e80756d9a71e9a7b0b298c0c45ba7b70083.tar.gz |
Auto merge of #2631 - devnexen:fbsd13_upd_shm, r=Amanieu
shm api update from FreeBSD 13
Diffstat (limited to 'src')
-rw-r--r-- | src/unix/bsd/freebsdlike/freebsd/mod.rs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/unix/bsd/freebsdlike/freebsd/mod.rs b/src/unix/bsd/freebsdlike/freebsd/mod.rs index a5c7c8cf00..c66e6df49c 100644 --- a/src/unix/bsd/freebsdlike/freebsd/mod.rs +++ b/src/unix/bsd/freebsdlike/freebsd/mod.rs @@ -3615,6 +3615,13 @@ pub const DST_CAN: ::c_int = 6; pub const CPUCLOCK_WHICH_PID: ::c_int = 0; pub const CPUCLOCK_WHICH_TID: ::c_int = 1; +pub const MFD_CLOEXEC: ::c_uint = 0x00000001; +pub const MFD_ALLOW_SEALING: ::c_uint = 0x00000002; +pub const MFD_HUGETLB: ::c_uint = 0x00000004; + +pub const SHM_RENAME_NOREPLACE: ::c_int = 1 << 0; +pub const SHM_RENAME_EXCHANGE: ::c_int = 1 << 1; + const_fn! { {const} fn _ALIGN(p: usize) -> usize { (p + _ALIGNBYTES) & !_ALIGNBYTES @@ -4155,6 +4162,13 @@ extern "C" { pub fn adjtime(arg1: *const ::timeval, arg2: *mut ::timeval) -> ::c_int; pub fn clock_getcpuclockid2(arg1: ::id_t, arg2: ::c_int, arg3: *mut clockid_t) -> ::c_int; + + pub fn shm_rename( + path_from: *const ::c_char, + path_to: *const ::c_char, + flags: ::c_int, + ) -> ::c_int; + pub fn memfd_create(name: *const ::c_char, flags: ::c_uint) -> ::c_int; } #[link(name = "kvm")] |