@@ -5,26 +5,81 @@ import (
55)
66
77const (
8- RDONLY = syscall .MS_RDONLY
9- NOSUID = syscall .MS_NOSUID
10- NODEV = syscall .MS_NODEV
11- NOEXEC = syscall .MS_NOEXEC
8+ // RDONLY will mount the file system read-only.
9+ RDONLY = syscall .MS_RDONLY
10+
11+ // NOSUID will not allow set-user-identifier or set-group-identifier bits to
12+ // take effect.
13+ NOSUID = syscall .MS_NOSUID
14+
15+ // NODEV will not interpret character or block special devices on the file
16+ // system.
17+ NODEV = syscall .MS_NODEV
18+
19+ // NOEXEC will not allow execution of any binaries on the mounted file system.
20+ NOEXEC = syscall .MS_NOEXEC
21+
22+ // SYNCHRONOUS will allow I/O to the file system to be done synchronously.
1223 SYNCHRONOUS = syscall .MS_SYNCHRONOUS
13- DIRSYNC = syscall .MS_DIRSYNC
14- REMOUNT = syscall .MS_REMOUNT
15- MANDLOCK = syscall .MS_MANDLOCK
16- NOATIME = syscall .MS_NOATIME
17- NODIRATIME = syscall .MS_NODIRATIME
18- BIND = syscall .MS_BIND
19- RBIND = syscall .MS_BIND | syscall .MS_REC
20- UNBINDABLE = syscall .MS_UNBINDABLE
24+
25+ // DIRSYNC will force all directory updates within the file system to be done
26+ // synchronously. This affects the following system calls: creat, link,
27+ // unlink, symlink, mkdir, rmdir, mknod and rename.
28+ DIRSYNC = syscall .MS_DIRSYNC
29+
30+ // REMOUNT will attempt to remount an already-mounted file system. This is
31+ // commonly used to change the mount flags for a file system, especially to
32+ // make a readonly file system writeable. It does not change device or mount
33+ // point.
34+ REMOUNT = syscall .MS_REMOUNT
35+
36+ // MANDLOCK will force mandatory locks on a filesystem.
37+ MANDLOCK = syscall .MS_MANDLOCK
38+
39+ // NOATIME will not update the file access time when reading from a file.
40+ NOATIME = syscall .MS_NOATIME
41+
42+ // NODIRATIME will not update the directory access time.
43+ NODIRATIME = syscall .MS_NODIRATIME
44+
45+ // BIND remounts a subtree somewhere else.
46+ BIND = syscall .MS_BIND
47+
48+ // RBIND remounts a subtree and all possible submounts somewhere else.
49+ RBIND = syscall .MS_BIND | syscall .MS_REC
50+
51+ // UNBINDABLE creates a mount which cannot be cloned through a bind operation.
52+ UNBINDABLE = syscall .MS_UNBINDABLE
53+
54+ // RUNBINDABLE marks the entire mount tree as UNBINDABLE.
2155 RUNBINDABLE = syscall .MS_UNBINDABLE | syscall .MS_REC
22- PRIVATE = syscall .MS_PRIVATE
23- RPRIVATE = syscall .MS_PRIVATE | syscall .MS_REC
24- SLAVE = syscall .MS_SLAVE
25- RSLAVE = syscall .MS_SLAVE | syscall .MS_REC
26- SHARED = syscall .MS_SHARED
27- RSHARED = syscall .MS_SHARED | syscall .MS_REC
28- RELATIME = syscall .MS_RELATIME
56+
57+ // PRIVATE creates a mount which carries no propagation abilities.
58+ PRIVATE = syscall .MS_PRIVATE
59+
60+ // RPRIVATE marks the entire mount tree as PRIVATE.
61+ RPRIVATE = syscall .MS_PRIVATE | syscall .MS_REC
62+
63+ // SLAVE creates a mount which receives propagation from its master, but not
64+ // vice versa.
65+ SLAVE = syscall .MS_SLAVE
66+
67+ // RSLAVE marks the entire mount tree as SLAVE.
68+ RSLAVE = syscall .MS_SLAVE | syscall .MS_REC
69+
70+ // SHARED creates a mount which provides the ability to create mirrors of
71+ // that mount such that mounts and unmounts within any of the mirrors
72+ // propagate to the other mirrors.
73+ SHARED = syscall .MS_SHARED
74+
75+ // RSHARED marks the entire mount tree as SHARED.
76+ RSHARED = syscall .MS_SHARED | syscall .MS_REC
77+
78+ // RELATIME updates inode access times relative to modify or change time.
79+ RELATIME = syscall .MS_RELATIME
80+
81+ // STRICTATIME allows to explicitly request full atime updates. This makes
82+ // it possible for the kernel to default to relatime or noatime but still
83+ // allow userspace to override it.
2984 STRICTATIME = syscall .MS_STRICTATIME
3085)
0 commit comments