hc
2023-12-08 01573e231f18eb2d99162747186f59511f56b64d
kernel/include/linux/mount.h
....@@ -22,6 +22,7 @@
2222 struct vfsmount;
2323 struct dentry;
2424 struct mnt_namespace;
25
+struct fs_context;
2526
2627 #define MNT_NOSUID 0x01
2728 #define MNT_NODEV 0x02
....@@ -30,6 +31,7 @@
3031 #define MNT_NODIRATIME 0x10
3132 #define MNT_RELATIME 0x20
3233 #define MNT_READONLY 0x40 /* does the user want this to be r/o? */
34
+#define MNT_NOSYMFOLLOW 0x80
3335
3436 #define MNT_SHRINKABLE 0x100
3537 #define MNT_WRITE_HOLD 0x200
....@@ -46,11 +48,12 @@
4648 #define MNT_SHARED_MASK (MNT_UNBINDABLE)
4749 #define MNT_USER_SETTABLE_MASK (MNT_NOSUID | MNT_NODEV | MNT_NOEXEC \
4850 | MNT_NOATIME | MNT_NODIRATIME | MNT_RELATIME \
49
- | MNT_READONLY)
51
+ | MNT_READONLY | MNT_NOSYMFOLLOW)
5052 #define MNT_ATIME_MASK (MNT_NOATIME | MNT_NODIRATIME | MNT_RELATIME )
5153
5254 #define MNT_INTERNAL_FLAGS (MNT_SHARED | MNT_WRITE_HOLD | MNT_INTERNAL | \
53
- MNT_DOOMED | MNT_SYNC_UMOUNT | MNT_MARKED)
55
+ MNT_DOOMED | MNT_SYNC_UMOUNT | MNT_MARKED | \
56
+ MNT_CURSOR)
5457
5558 #define MNT_INTERNAL 0x4000
5659
....@@ -64,16 +67,17 @@
6467 #define MNT_SYNC_UMOUNT 0x2000000
6568 #define MNT_MARKED 0x4000000
6669 #define MNT_UMOUNT 0x8000000
70
+#define MNT_CURSOR 0x10000000
6771
6872 struct vfsmount {
6973 struct dentry *mnt_root; /* root of the mounted tree */
7074 struct super_block *mnt_sb; /* pointer to superblock */
7175 int mnt_flags;
76
+
7277 ANDROID_KABI_RESERVE(1);
7378 ANDROID_KABI_RESERVE(2);
7479 ANDROID_KABI_RESERVE(3);
7580 ANDROID_KABI_RESERVE(4);
76
- void *data;
7781 } __randomize_layout;
7882
7983 struct file; /* forward dec */
....@@ -87,7 +91,7 @@
8791 extern void mntput(struct vfsmount *mnt);
8892 extern struct vfsmount *mntget(struct vfsmount *mnt);
8993 extern struct vfsmount *mnt_clone_internal(const struct path *path);
90
-extern int __mnt_is_readonly(struct vfsmount *mnt);
94
+extern bool __mnt_is_readonly(struct vfsmount *mnt);
9195 extern bool mnt_may_suid(struct vfsmount *mnt);
9296
9397 struct path;
....@@ -96,6 +100,8 @@
96100 extern void __mnt_drop_write(struct vfsmount *);
97101
98102 struct file_system_type;
103
+extern struct vfsmount *fc_mount(struct fs_context *fc);
104
+extern struct vfsmount *vfs_create_mount(struct fs_context *fc);
99105 extern struct vfsmount *vfs_kern_mount(struct file_system_type *type,
100106 int flags, const char *name,
101107 void *data);
....@@ -112,4 +118,6 @@
112118
113119 extern bool path_is_mountpoint(const struct path *path);
114120
121
+extern void kern_unmount_array(struct vfsmount *mnt[], unsigned int num);
122
+
115123 #endif /* _LINUX_MOUNT_H */