• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 s! {
2     pub struct shmid_ds {
3         pub shm_perm: ::ipc_perm,
4         pub shm_segsz: ::size_t,
5         pub shm_amp: *mut ::c_void,
6         pub shm_lkcnt: ::c_ushort,
7         pub shm_lpid: ::pid_t,
8         pub shm_cpid: ::pid_t,
9         pub shm_nattch: ::shmatt_t,
10         pub shm_cnattch: ::c_ulong,
11         pub shm_atime: ::time_t,
12         pub shm_dtime: ::time_t,
13         pub shm_ctime: ::time_t,
14         pub shm_pad4: [i64; 4],
15     }
16 }
17 
18 pub const AF_LOCAL: ::c_int = 1; // AF_UNIX
19 pub const AF_FILE: ::c_int = 1; // AF_UNIX
20 
21 pub const EFD_SEMAPHORE: ::c_int = 0x1;
22 pub const EFD_NONBLOCK: ::c_int = 0x800;
23 pub const EFD_CLOEXEC: ::c_int = 0x80000;
24 
25 pub const TCP_KEEPIDLE: ::c_int = 34;
26 pub const TCP_KEEPCNT: ::c_int = 35;
27 pub const TCP_KEEPINTVL: ::c_int = 36;
28 pub const TCP_CONGESTION: ::c_int = 37;
29 
30 pub const F_OFD_GETLK: ::c_int = 50;
31 pub const F_OFD_SETLKL: ::c_int = 51;
32 pub const F_OFD_SETLKW: ::c_int = 52;
33 pub const F_FLOCK: ::c_int = 55;
34 pub const F_FLOCKW: ::c_int = 56;
35 
36 extern "C" {
eventfd(init: ::c_uint, flags: ::c_int) -> ::c_int37     pub fn eventfd(init: ::c_uint, flags: ::c_int) -> ::c_int;
38 
mincore(addr: ::caddr_t, len: ::size_t, vec: *mut ::c_char) -> ::c_int39     pub fn mincore(addr: ::caddr_t, len: ::size_t, vec: *mut ::c_char) -> ::c_int;
40 }
41