Skip to content

Commit

Permalink
Auto merge of rust-lang#229 - kamalmarhubi:mount-flags, r=alexcrichton
Browse files Browse the repository at this point in the history
linux: Move some MS_flags for mount(2) up

These flags are available on Android.
  • Loading branch information
bors committed Mar 15, 2016
2 parents aabff31 + 10bfe07 commit fa161ae
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
5 changes: 0 additions & 5 deletions src/unix/notbsd/linux/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -361,11 +361,6 @@ pub const SHM_UNLOCK: ::c_int = 12;
pub const SHM_HUGETLB: ::c_int = 0o4000;
pub const SHM_NORESERVE: ::c_int = 0o10000;

pub const MS_RELATIME: ::c_ulong = 0x200000;
pub const MS_KERNMOUNT: ::c_ulong = 0x400000;
pub const MS_I_VERSION: ::c_ulong = 0x800000;
pub const MS_STRICTATIME: ::c_ulong = 0x01000000;

pub const EPOLLRDHUP: ::c_int = 0x2000;
pub const EPOLLONESHOT: ::c_int = 0x40000000;

Expand Down
7 changes: 7 additions & 0 deletions src/unix/notbsd/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -244,9 +244,12 @@ pub const MAP_FAILED: *mut ::c_void = !0 as *mut ::c_void;
pub const MCL_CURRENT: ::c_int = 0x0001;
pub const MCL_FUTURE: ::c_int = 0x0002;

// MS_ flags for msync(2)
pub const MS_ASYNC: ::c_int = 0x0001;
pub const MS_INVALIDATE: ::c_int = 0x0002;
pub const MS_SYNC: ::c_int = 0x0004;

// MS_ flags for mount(2)
pub const MS_RDONLY: ::c_ulong = 0x01;
pub const MS_NOSUID: ::c_ulong = 0x02;
pub const MS_NODEV: ::c_ulong = 0x04;
Expand All @@ -266,6 +269,10 @@ pub const MS_UNBINDABLE: ::c_ulong = 0x020000;
pub const MS_PRIVATE: ::c_ulong = 0x040000;
pub const MS_SLAVE: ::c_ulong = 0x080000;
pub const MS_SHARED: ::c_ulong = 0x100000;
pub const MS_RELATIME: ::c_ulong = 0x200000;
pub const MS_KERNMOUNT: ::c_ulong = 0x400000;
pub const MS_I_VERSION: ::c_ulong = 0x800000;
pub const MS_STRICTATIME: ::c_ulong = 0x1000000;
pub const MS_ACTIVE: ::c_ulong = 0x40000000;
pub const MS_NOUSER: ::c_ulong = 0x80000000;
pub const MS_MGC_VAL: ::c_ulong = 0xc0ed0000;
Expand Down

0 comments on commit fa161ae

Please sign in to comment.