diff options
Diffstat (limited to 'tools/include/uapi/linux/fs.h')
| -rw-r--r-- | tools/include/uapi/linux/fs.h | 60 |
1 files changed, 8 insertions, 52 deletions
diff --git a/tools/include/uapi/linux/fs.h b/tools/include/uapi/linux/fs.h index a441ea1bfe6d..121e82ce296b 100644 --- a/tools/include/uapi/linux/fs.h +++ b/tools/include/uapi/linux/fs.h | |||
| @@ -14,6 +14,11 @@ | |||
| 14 | #include <linux/ioctl.h> | 14 | #include <linux/ioctl.h> |
| 15 | #include <linux/types.h> | 15 | #include <linux/types.h> |
| 16 | 16 | ||
| 17 | /* Use of MS_* flags within the kernel is restricted to core mount(2) code. */ | ||
| 18 | #if !defined(__KERNEL__) | ||
| 19 | #include <linux/mount.h> | ||
| 20 | #endif | ||
| 21 | |||
| 17 | /* | 22 | /* |
| 18 | * It's silly to have NR_OPEN bigger than NR_FILE, but you can change | 23 | * It's silly to have NR_OPEN bigger than NR_FILE, but you can change |
| 19 | * the file limit at runtime and only root can increase the per-process | 24 | * the file limit at runtime and only root can increase the per-process |
| @@ -101,57 +106,6 @@ struct inodes_stat_t { | |||
| 101 | 106 | ||
| 102 | #define NR_FILE 8192 /* this can well be larger on a larger system */ | 107 | #define NR_FILE 8192 /* this can well be larger on a larger system */ |
| 103 | 108 | ||
| 104 | |||
| 105 | /* | ||
| 106 | * These are the fs-independent mount-flags: up to 32 flags are supported | ||
| 107 | */ | ||
| 108 | #define MS_RDONLY 1 /* Mount read-only */ | ||
| 109 | #define MS_NOSUID 2 /* Ignore suid and sgid bits */ | ||
| 110 | #define MS_NODEV 4 /* Disallow access to device special files */ | ||
| 111 | #define MS_NOEXEC 8 /* Disallow program execution */ | ||
| 112 | #define MS_SYNCHRONOUS 16 /* Writes are synced at once */ | ||
| 113 | #define MS_REMOUNT 32 /* Alter flags of a mounted FS */ | ||
| 114 | #define MS_MANDLOCK 64 /* Allow mandatory locks on an FS */ | ||
| 115 | #define MS_DIRSYNC 128 /* Directory modifications are synchronous */ | ||
| 116 | #define MS_NOATIME 1024 /* Do not update access times. */ | ||
| 117 | #define MS_NODIRATIME 2048 /* Do not update directory access times */ | ||
| 118 | #define MS_BIND 4096 | ||
| 119 | #define MS_MOVE 8192 | ||
| 120 | #define MS_REC 16384 | ||
| 121 | #define MS_VERBOSE 32768 /* War is peace. Verbosity is silence. | ||
| 122 | MS_VERBOSE is deprecated. */ | ||
| 123 | #define MS_SILENT 32768 | ||
| 124 | #define MS_POSIXACL (1<<16) /* VFS does not apply the umask */ | ||
| 125 | #define MS_UNBINDABLE (1<<17) /* change to unbindable */ | ||
| 126 | #define MS_PRIVATE (1<<18) /* change to private */ | ||
| 127 | #define MS_SLAVE (1<<19) /* change to slave */ | ||
| 128 | #define MS_SHARED (1<<20) /* change to shared */ | ||
| 129 | #define MS_RELATIME (1<<21) /* Update atime relative to mtime/ctime. */ | ||
| 130 | #define MS_KERNMOUNT (1<<22) /* this is a kern_mount call */ | ||
| 131 | #define MS_I_VERSION (1<<23) /* Update inode I_version field */ | ||
| 132 | #define MS_STRICTATIME (1<<24) /* Always perform atime updates */ | ||
| 133 | #define MS_LAZYTIME (1<<25) /* Update the on-disk [acm]times lazily */ | ||
| 134 | |||
| 135 | /* These sb flags are internal to the kernel */ | ||
| 136 | #define MS_SUBMOUNT (1<<26) | ||
| 137 | #define MS_NOREMOTELOCK (1<<27) | ||
| 138 | #define MS_NOSEC (1<<28) | ||
| 139 | #define MS_BORN (1<<29) | ||
| 140 | #define MS_ACTIVE (1<<30) | ||
| 141 | #define MS_NOUSER (1<<31) | ||
| 142 | |||
| 143 | /* | ||
| 144 | * Superblock flags that can be altered by MS_REMOUNT | ||
| 145 | */ | ||
| 146 | #define MS_RMT_MASK (MS_RDONLY|MS_SYNCHRONOUS|MS_MANDLOCK|MS_I_VERSION|\ | ||
| 147 | MS_LAZYTIME) | ||
| 148 | |||
| 149 | /* | ||
| 150 | * Old magic mount flag and mask | ||
| 151 | */ | ||
| 152 | #define MS_MGC_VAL 0xC0ED0000 | ||
| 153 | #define MS_MGC_MSK 0xffff0000 | ||
| 154 | |||
| 155 | /* | 109 | /* |
| 156 | * Structure for FS_IOC_FSGETXATTR[A] and FS_IOC_FSSETXATTR. | 110 | * Structure for FS_IOC_FSGETXATTR[A] and FS_IOC_FSSETXATTR. |
| 157 | */ | 111 | */ |
| @@ -269,7 +223,8 @@ struct fsxattr { | |||
| 269 | #define FS_POLICY_FLAGS_PAD_16 0x02 | 223 | #define FS_POLICY_FLAGS_PAD_16 0x02 |
| 270 | #define FS_POLICY_FLAGS_PAD_32 0x03 | 224 | #define FS_POLICY_FLAGS_PAD_32 0x03 |
| 271 | #define FS_POLICY_FLAGS_PAD_MASK 0x03 | 225 | #define FS_POLICY_FLAGS_PAD_MASK 0x03 |
| 272 | #define FS_POLICY_FLAGS_VALID 0x03 | 226 | #define FS_POLICY_FLAG_DIRECT_KEY 0x04 /* use master key directly */ |
| 227 | #define FS_POLICY_FLAGS_VALID 0x07 | ||
| 273 | 228 | ||
| 274 | /* Encryption algorithms */ | 229 | /* Encryption algorithms */ |
| 275 | #define FS_ENCRYPTION_MODE_INVALID 0 | 230 | #define FS_ENCRYPTION_MODE_INVALID 0 |
| @@ -281,6 +236,7 @@ struct fsxattr { | |||
| 281 | #define FS_ENCRYPTION_MODE_AES_128_CTS 6 | 236 | #define FS_ENCRYPTION_MODE_AES_128_CTS 6 |
| 282 | #define FS_ENCRYPTION_MODE_SPECK128_256_XTS 7 /* Removed, do not use. */ | 237 | #define FS_ENCRYPTION_MODE_SPECK128_256_XTS 7 /* Removed, do not use. */ |
| 283 | #define FS_ENCRYPTION_MODE_SPECK128_256_CTS 8 /* Removed, do not use. */ | 238 | #define FS_ENCRYPTION_MODE_SPECK128_256_CTS 8 /* Removed, do not use. */ |
| 239 | #define FS_ENCRYPTION_MODE_ADIANTUM 9 | ||
| 284 | 240 | ||
| 285 | struct fscrypt_policy { | 241 | struct fscrypt_policy { |
| 286 | __u8 version; | 242 | __u8 version; |
