/linux-master/tools/testing/selftests/memfd/ |
H A D | run_fuse_test.sh | 4 if test -d "./mnt" ; then 5 fusermount -u ./mnt 6 rmdir ./mnt 11 mkdir mnt 12 ./fuse_mnt ./mnt 13 ./fuse_test ./mnt/memfd $@ 14 fusermount -u ./mnt 15 rmdir ./mnt
|
/linux-master/fs/ |
H A D | pnode.c | 37 static struct mount *get_peer_under_root(struct mount *mnt, argument 41 struct mount *m = mnt; 45 if (m->mnt_ns == ns && is_path_reachable(m, m->mnt.mnt_root, root)) 49 } while (m != mnt); 60 int get_dominating_id(struct mount *mnt, const struct path *root) argument 64 for (m = mnt->mnt_master; m != NULL; m = m->mnt_master) { 65 struct mount *d = get_peer_under_root(m, mnt->mnt_ns, root); 73 static int do_make_slave(struct mount *mnt) argument 77 if (list_empty(&mnt->mnt_share)) { 78 if (IS_MNT_SHARED(mnt)) { 122 change_mnt_propagation(struct mount *mnt, int type) argument 334 find_topper(struct mount *mnt) argument 352 do_refcount_check(struct mount *mnt, int count) argument 407 propagate_mount_busy(struct mount *mnt, int refcnt) argument 450 propagate_mount_unlock(struct mount *mnt) argument 465 umount_one(struct mount *mnt, struct list_head *to_umount) argument 478 __propagate_umount(struct mount *mnt, struct list_head *to_umount, struct list_head *to_restore) argument 522 struct mount *mnt, *child, *tmp; local 538 struct mount *mnt, *parent; local 560 struct mount *mnt = local 575 struct mount *mnt; local [all...] |
H A D | pnode.h | 13 #define IS_MNT_SHARED(m) ((m)->mnt.mnt_flags & MNT_SHARED) 16 #define CLEAR_MNT_SHARED(m) ((m)->mnt.mnt_flags &= ~MNT_SHARED) 17 #define IS_MNT_UNBINDABLE(m) ((m)->mnt.mnt_flags & MNT_UNBINDABLE) 18 #define IS_MNT_MARKED(m) ((m)->mnt.mnt_flags & MNT_MARKED) 19 #define SET_MNT_MARK(m) ((m)->mnt.mnt_flags |= MNT_MARKED) 20 #define CLEAR_MNT_MARK(m) ((m)->mnt.mnt_flags &= ~MNT_MARKED) 21 #define IS_MNT_LOCKED(m) ((m)->mnt.mnt_flags & MNT_LOCKED) 33 static inline void set_mnt_shared(struct mount *mnt) argument 35 mnt->mnt [all...] |
H A D | namespace.c | 116 static inline struct hlist_head *m_hash(struct vfsmount *mnt, struct dentry *dentry) argument 118 unsigned long tmp = ((unsigned long)mnt / L1_CACHE_BYTES); 131 static int mnt_alloc_id(struct mount *mnt) argument 137 mnt->mnt_id = res; 138 mnt->mnt_id_unique = atomic64_inc_return(&mnt_id_ctr); 142 static void mnt_free_id(struct mount *mnt) argument 144 ida_free(&mnt_id_ida, mnt->mnt_id); 150 static int mnt_alloc_group_id(struct mount *mnt) argument 156 mnt->mnt_group_id = res; 163 void mnt_release_group_id(struct mount *mnt) argument 172 mnt_add_count(struct mount *mnt, int n) argument 186 mnt_get_count(struct mount *mnt) argument 204 struct mount *mnt = kmem_cache_zalloc(mnt_cache, GFP_KERNEL); local 275 __mnt_is_readonly(struct vfsmount *mnt) argument 281 mnt_inc_writers(struct mount *mnt) argument 290 mnt_dec_writers(struct mount *mnt) argument 299 mnt_get_writers(struct mount *mnt) argument 315 mnt_is_readonly(struct vfsmount *mnt) argument 349 struct mount *mnt = real_mount(m); local 469 mnt_put_write_access(struct vfsmount *mnt) argument 485 mnt_drop_write(struct vfsmount *mnt) argument 523 mnt_hold_writers(struct mount *mnt) argument 566 mnt_unhold_writers(struct mount *mnt) argument 576 mnt_make_readonly(struct mount *mnt) argument 589 struct mount *mnt; local 618 free_vfsmnt(struct mount *mnt) argument 636 struct mount *mnt; local 695 __lookup_mnt(struct vfsmount *mnt, struct dentry *dentry) argument 756 struct mount *mnt, *n; local 858 check_mnt(struct mount *mnt) argument 888 unhash_mnt(struct mount *mnt) argument 904 umount_mnt(struct mount *mnt) argument 912 mnt_set_mountpoint(struct mount *mnt, struct mountpoint *mp, struct mount *child_mnt) argument 951 __attach_mnt(struct mount *mnt, struct mount *parent) argument 980 attach_mnt(struct mount *mnt, struct mount *parent, struct mountpoint *mp, bool beneath) argument 996 mnt_change_mountpoint(struct mount *parent, struct mountpoint *mp, struct mount *mnt) argument 1016 mnt_add_to_ns(struct mnt_namespace *ns, struct mount *mnt) argument 1038 commit_tree(struct mount *mnt) argument 1098 struct mount *mnt; local 1139 struct vfsmount *mnt; local 1183 struct mount *mnt; local 1247 cleanup_mnt(struct mount *mnt) argument 1288 mntput_no_expire(struct mount *mnt) argument 1356 mntput(struct vfsmount *mnt) argument 1368 mntget(struct vfsmount *mnt) argument 1381 mnt_make_shortterm(struct vfsmount *mnt) argument 1465 struct mount *next = NULL, *mnt = v; local 1507 struct mount *mnt = real_mount(m); local 1542 may_umount(struct vfsmount *mnt) argument 1592 disconnect_mount(struct mount *mnt, enum umount_tree_flags how) argument 1625 umount_tree(struct mount *mnt, enum umount_tree_flags how) argument 1707 do_umount(struct mount *mnt, int flags) argument 1818 struct mount *mnt; local 1873 struct mount *mnt = real_mount(path->mnt); local 1891 struct mount *mnt = real_mount(path->mnt); local 1951 from_mnt_ns(struct mnt_namespace *mnt) argument 1969 copy_tree(struct mount *mnt, struct dentry *dentry, int flag) argument 2054 dissolve_on_fput(struct vfsmount *mnt) argument 2072 drop_collected_mounts(struct vfsmount *mnt) argument 2081 has_locked_children(struct mount *mnt, struct dentry *dentry) argument 2140 struct mount *mnt; local 2152 lock_mnt_tree(struct mount *mnt) argument 2179 cleanup_group_ids(struct mount *mnt, struct mount *end) argument 2189 invent_group_ids(struct mount *mnt, bool recurse) argument 2206 count_mounts(struct mnt_namespace *ns, struct mount *mnt) argument 2444 struct vfsmount *mnt = path->mnt; local 2517 graft_tree(struct mount *mnt, struct mount *p, struct mountpoint *mp) argument 2552 struct mount *mnt = real_mount(path->mnt); local 2583 struct mount *mnt = ERR_PTR(-EINVAL), *old = real_mount(old_path->mnt); local 2612 struct mount *mnt = NULL, *parent; local 2658 struct mount *mnt, *p; local 2749 can_change_locked_flags(struct mount *mnt, unsigned int mnt_flags) argument 2776 change_mount_ro_state(struct mount *mnt, unsigned int mnt_flags) argument 2790 set_mount_attributes(struct mount *mnt, unsigned int mnt_flags) argument 2797 mnt_warn_timestamp_expiry(struct path *mountpoint, struct vfsmount *mnt) argument 2826 struct mount *mnt = real_mount(path->mnt); local 2865 struct mount *mnt = real_mount(path->mnt); local 2908 tree_contains_unbindable(struct mount *mnt) argument 3267 struct vfsmount *mnt; local 3364 struct mount *mnt; local 3432 mnt_set_expiry(struct vfsmount *mnt, struct list_head *expiry_list) argument 3449 struct mount *mnt, *next; local 3498 struct mount *mnt = list_entry(tmp, struct mount, mnt_child); local 3533 shrink_submounts(struct mount *mnt) argument 3841 struct mount *mnt = real_mount(m); local 3950 struct mount *mnt; local 4134 is_path_reachable(struct mount *mnt, struct dentry *dentry, const struct path *root) argument 4278 recalc_flags(struct mount_kattr *kattr, struct mount *mnt) argument 4290 can_idmap_mount(const struct mount_kattr *kattr, struct mount *mnt) argument 4337 mnt_allow_writers(const struct mount_kattr *kattr, const struct mount *mnt) argument 4345 mount_setattr_prepare(struct mount_kattr *kattr, struct mount *mnt) argument 4394 do_idmap_mount(const struct mount_kattr *kattr, struct mount *mnt) argument 4410 mount_setattr_commit(struct mount_kattr *kattr, struct mount *mnt) argument 4435 struct mount *mnt = real_mount(path->mnt); local 4706 struct mount *mnt = mnt_find_id_at(ns, id); local 4717 struct vfsmount *mnt; member in struct:kstatmount 4724 mnt_to_attr_flags(struct vfsmount *mnt) argument 4830 struct vfsmount *mnt = s->mnt; local 5004 struct vfsmount *mnt; local 5135 struct vfsmount *mnt; local 5207 struct vfsmount *mnt; local 5220 kern_unmount(struct vfsmount *mnt) argument 5231 kern_unmount_array(struct vfsmount *mnt[], unsigned int num) argument 5243 our_mnt(struct vfsmount *mnt) argument 5277 struct mount *mnt, *n; local 5359 mnt_may_suid(struct vfsmount *mnt) argument [all...] |
H A D | mount.h | 37 struct vfsmount mnt; member in struct:mount 82 static inline struct mount *real_mount(struct vfsmount *mnt) argument 84 return container_of(mnt, struct mount, mnt); 87 static inline int mnt_has_parent(struct mount *mnt) argument 89 return mnt != mnt->mnt_parent; 92 static inline int is_mounted(struct vfsmount *mnt) argument 95 return !IS_ERR_OR_NULL(real_mount(mnt)->mnt_ns); 104 struct mount *m = __lookup_mnt(path->mnt, pat 146 move_from_ns(struct mount *mnt, struct list_head *dt_list) argument [all...] |
H A D | proc_namespace.c | 64 static void show_mnt_opts(struct seq_file *m, struct vfsmount *mnt) argument 79 if (mnt->mnt_flags & fs_infop->flag) 83 if (is_idmapped_mnt(mnt)) 101 static int show_vfsmnt(struct seq_file *m, struct vfsmount *mnt) argument 104 struct mount *r = real_mount(mnt); 105 struct path mnt_path = { .dentry = mnt->mnt_root, .mnt = mnt }; 123 seq_puts(m, __mnt_is_readonly(mnt) ? " ro" : " rw"); 127 show_mnt_opts(m, mnt); 135 show_mountinfo(struct seq_file *m, struct vfsmount *mnt) argument 193 show_vfsstat(struct seq_file *m, struct vfsmount *mnt) argument [all...] |
H A D | fhandle.c | 72 if (put_user(real_mount(path->mnt)->mnt_id, mnt_id) || 120 struct vfsmount *mnt; local 125 mnt = mntget(fs->pwd.mnt); 131 mnt = mntget(f.file->f_path.mnt); 134 return mnt; 148 path->mnt = get_vfsmount_from_fd(mountdirfd); 149 if (IS_ERR(path->mnt)) { 150 retval = PTR_ERR(path->mnt); [all...] |
H A D | d_path.c | 104 static int __prepend_path(const struct dentry *dentry, const struct mount *mnt, argument 107 while (dentry != root->dentry || &mnt->mnt != root->mnt) { 110 if (dentry == mnt->mnt.mnt_root) { 111 struct mount *m = READ_ONCE(mnt->mnt_parent); 114 if (likely(mnt != m)) { 115 dentry = READ_ONCE(mnt->mnt_mountpoint); 116 mnt [all...] |
H A D | namei.c | 548 mntget(path->mnt); 562 mntput(path->mnt); 602 p->path.mnt = NULL; 645 * path_connected - Verify that a dentry is below mnt.mnt_root 646 * @mnt: The mountpoint to check. 652 static bool path_connected(struct vfsmount *mnt, struct dentry *dentry) argument 654 struct super_block *sb = mnt->mnt_sb; 657 if (mnt->mnt_root == sb->s_root) 660 return is_subdir(dentry, mnt->mnt_root); 696 nd->path.mnt 1274 struct mount *mnt = real_mount(path->mnt); local 1380 struct vfsmount *mnt = path->mnt; local 1468 struct vfsmount *mnt = path->mnt; local 2656 vfs_path_lookup(struct dentry *dentry, struct vfsmount *mnt, const char *name, unsigned int flags, struct path *path) argument [all...] |
H A D | file_table.c | 326 struct vfsmount *mnt, struct path *path) 330 path->dentry = d_alloc_pseudo(mnt->mnt_sb, &this); 333 path->mnt = mntget(mnt); 338 struct file *alloc_file_pseudo(struct inode *inode, struct vfsmount *mnt, argument 346 ret = alloc_path_pseudo(name, inode, mnt, &path); 360 struct vfsmount *mnt, const char *name, 368 ret = alloc_path_pseudo(name, inode, mnt, &path); 399 struct vfsmount *mnt = file->f_path.mnt; local 325 alloc_path_pseudo(const char *name, struct inode *inode, struct vfsmount *mnt, struct path *path) argument 359 alloc_file_pseudo_noaccount(struct inode *inode, struct vfsmount *mnt, const char *name, int flags, const struct file_operations *fops) argument [all...] |
/linux-master/tools/lib/api/fs/ |
H A D | tracing_path.c | 26 const char *mnt; local 28 mnt = tracefs__mount(); 29 if (!mnt) 32 __tracing_path_set("", mnt); 39 const char *mnt; local 41 mnt = debugfs__mount(); 42 if (!mnt) 45 __tracing_path_set("tracing/", mnt); 52 const char *mnt; local 54 mnt [all...] |
/linux-master/include/linux/ |
H A D | path.h | 9 struct vfsmount *mnt; member in struct:path 18 return path1->mnt == path2->mnt && path1->dentry == path2->dentry;
|
H A D | mount.h | 76 static inline struct mnt_idmap *mnt_idmap(const struct vfsmount *mnt) argument 79 return smp_load_acquire(&mnt->mnt_idmap); 82 extern int mnt_want_write(struct vfsmount *mnt); 84 extern void mnt_drop_write(struct vfsmount *mnt); 86 extern void mntput(struct vfsmount *mnt); 87 extern struct vfsmount *mntget(struct vfsmount *mnt); 88 extern void mnt_make_shortterm(struct vfsmount *mnt); 90 extern bool __mnt_is_readonly(struct vfsmount *mnt); 91 extern bool mnt_may_suid(struct vfsmount *mnt); 94 int mnt_get_write_access(struct vfsmount *mnt); [all...] |
/linux-master/kernel/ |
H A D | usermode_driver.c | 15 struct vfsmount *mnt; local 24 mnt = kern_mount(type); 26 if (IS_ERR(mnt)) 27 return mnt; 29 file = file_open_root_mnt(mnt, name, O_CREAT | O_WRONLY, 0700); 31 kern_unmount(mnt); 41 kern_unmount(mnt); 50 return mnt; 62 struct vfsmount *mnt; local 64 if (WARN_ON_ONCE(info->wd.dentry || info->wd.mnt)) [all...] |
/linux-master/tools/bpf/bpftool/ |
H A D | tracelog.c | 27 static int validate_tracefs_mnt(const char *mnt, unsigned long magic) argument 31 if (statfs(mnt, &st_fs) < 0) 40 find_tracefs_mnt_single(unsigned long magic, char *mnt, const char *mntpt) argument 53 strcpy(mnt, mntpt); 57 static bool get_tracefs_pipe(char *mnt) argument 73 if (find_tracefs_mnt_single(TRACEFS_MAGIC, mnt, *ptr)) 83 while (fscanf(fp, format, mnt, type) == 2) 90 /* The string from fscanf() might be truncated, check mnt is valid */ 91 if (found && validate_tracefs_mnt(mnt, TRACEFS_MAGIC)) 103 strcpy(mnt, known_mnt [all...] |
/linux-master/security/tomoyo/ |
H A D | tomoyo.c | 160 struct path path = { .mnt = parent->mnt, .dentry = dentry }; 177 struct path path = { .mnt = parent->mnt, .dentry = dentry }; 193 struct path path = { .mnt = parent->mnt, .dentry = dentry }; 210 struct path path = { .mnt = parent->mnt, .dentry = dentry }; 228 struct path path = { .mnt = parent->mnt, 426 tomoyo_sb_umount(struct vfsmount *mnt, int flags) argument [all...] |
/linux-master/fs/autofs/ |
H A D | expire.c | 29 static int autofs_mount_busy(struct vfsmount *mnt, argument 33 struct path path = {.mnt = mnt, .dentry = dentry}; 58 if (!may_umount_tree(path.mnt)) { 147 static int autofs_direct_busy(struct vfsmount *mnt, argument 159 if (!may_umount_tree(mnt)) { 179 static int autofs_tree_busy(struct vfsmount *mnt, argument 204 if (autofs_mount_busy(mnt, p, how)) { 238 static struct dentry *autofs_check_leaves(struct vfsmount *mnt, argument 253 if (autofs_mount_busy(mnt, 271 autofs_expire_direct(struct super_block *sb, struct vfsmount *mnt, struct autofs_sb_info *sbi, unsigned int how) argument 318 should_expire(struct dentry *dentry, struct vfsmount *mnt, unsigned long timeout, unsigned int how) argument 417 autofs_expire_indirect(struct super_block *sb, struct vfsmount *mnt, struct autofs_sb_info *sbi, unsigned int how) argument 533 autofs_expire_run(struct super_block *sb, struct vfsmount *mnt, struct autofs_sb_info *sbi, struct autofs_packet_expire __user *pkt_p) argument 572 autofs_do_expire_multi(struct super_block *sb, struct vfsmount *mnt, struct autofs_sb_info *sbi, unsigned int how) argument 608 autofs_expire_multi(struct super_block *sb, struct vfsmount *mnt, struct autofs_sb_info *sbi, int __user *arg) argument [all...] |
/linux-master/fs/exportfs/ |
H A D | expfs.c | 27 static int exportfs_get_name(struct vfsmount *mnt, struct dentry *dir, argument 31 struct path path = {.mnt = mnt, .dentry = dir}; 121 static struct dentry *reconnect_one(struct vfsmount *mnt, argument 130 if (mnt->mnt_sb->s_export_op->get_parent) 131 parent = mnt->mnt_sb->s_export_op->get_parent(dentry); 142 err = exportfs_get_name(mnt, parent, nbuf, dentry); 148 tmp = lookup_one_unlocked(mnt_idmap(mnt), nbuf, parent, strlen(nbuf)); 212 reconnect_path(struct vfsmount *mnt, struct dentry *target_dir, char *nbuf) argument 219 BUG_ON(dentry == mnt 429 exportfs_decode_fh_raw(struct vfsmount *mnt, struct fid *fid, int fh_len, int fileid_type, int (*acceptable)(void *, struct dentry *), void *context) argument 577 exportfs_decode_fh(struct vfsmount *mnt, struct fid *fid, int fh_len, int fileid_type, int (*acceptable)(void *, struct dentry *), void *context) argument [all...] |
/linux-master/fs/notify/ |
H A D | fsnotify.h | 37 return fsnotify_conn_mount(conn)->mnt.mnt_sb; 63 static inline void fsnotify_clear_marks_by_mount(struct vfsmount *mnt) argument 65 fsnotify_destroy_marks(&real_mount(mnt)->mnt_fsnotify_marks);
|
H A D | fsnotify.c | 26 void __fsnotify_vfsmount_delete(struct vfsmount *mnt) argument 28 fsnotify_clear_marks_by_mount(mnt); 191 __u32 mnt_mask = path ? real_mount(path->mnt)->mnt_fsnotify_mask : 0; 493 struct mount *mnt = NULL; local 501 mnt = real_mount(path->mnt); 529 (!mnt || !mnt->mnt_fsnotify_marks) && 535 if (mnt) 536 marks_mask |= mnt [all...] |
/linux-master/tools/perf/util/ |
H A D | cgroup.c | 34 char mnt[PATH_MAX + 1]; local 38 if (cgroupfs_find_mountpoint(mnt, PATH_MAX + 1, "perf_event")) 41 scnprintf(path, PATH_MAX, "%s/%s", mnt, name); 69 char mnt[PATH_MAX + 1]; local 71 if (cgroupfs_find_mountpoint(mnt, PATH_MAX + 1, "perf_event")) 74 scnprintf(path, PATH_MAX, "%s/%s", mnt, cgrp->name); 89 char mnt[PATH_MAX + 1]; local 92 if (cgroupfs_find_mountpoint(mnt, PATH_MAX + 1, subsys)) 95 if (statfs(mnt, &stbuf) < 0) 302 char mnt[PATH_MA local 606 char mnt[PATH_MAX]; local [all...] |
/linux-master/fs/cachefiles/ |
H A D | cache.c | 43 cache->mnt = path.mnt; 47 if (is_idmapped_mnt(path.mnt)) { 166 mntput(cache->mnt); 167 cache->mnt = NULL; 193 .mnt = cache->mnt, 194 .dentry = cache->mnt->mnt_root, 353 down_read(&cache->mnt->mnt_sb->s_umount); 354 ret = sync_filesystem(cache->mnt [all...] |
/linux-master/security/apparmor/ |
H A D | mount.c | 91 if (ad->mnt.type) { 93 audit_log_untrustedstring(ab, ad->mnt.type); 95 if (ad->mnt.src_name) { 97 audit_log_untrustedstring(ab, ad->mnt.src_name); 99 if (ad->mnt.trans) { 101 audit_log_untrustedstring(ab, ad->mnt.trans); 103 if (ad->mnt.flags) { 105 audit_mnt_flags(ab, ad->mnt.flags); 108 if (ad->mnt.data) { 110 audit_log_untrustedstring(ab, ad->mnt 636 aa_umount(const struct cred *subj_cred, struct aa_label *label, struct vfsmount *mnt, int flags) argument [all...] |
/linux-master/fs/smb/client/ |
H A D | namespace.c | 198 struct vfsmount *mnt; local 205 fc = fs_context_for_submount(path->mnt->mnt_sb->s_type, mntpt); 214 mnt = ERR_CAST(full_path); 227 mnt = ERR_PTR(rc); 233 mnt = ERR_PTR(rc); 239 mnt = ERR_CAST(ctx->source); 247 mnt = fc_mount(fc); 251 return mnt;
|
/linux-master/tools/testing/selftests/mm/ |
H A D | charge_reserved_hugetlb.sh | 54 if [[ -e /mnt/huge ]]; then 55 rm -rf /mnt/huge/* 56 umount /mnt/huge || echo error 57 rmdir /mnt/huge 262 if [[ -e /mnt/huge ]]; then 263 rm -rf /mnt/huge/* 264 umount /mnt/huge 265 rmdir /mnt/huge 292 mkdir -p /mnt/huge 293 mount -t hugetlbfs -o pagesize=${MB}M,size=256M none /mnt/hug [all...] |