• Home
  • Raw
  • Download

Lines Matching refs:mnt_flags

249 	return (mnt->mnt_flags & MNT_READONLY) || sb_rdonly(mnt->mnt_sb);  in __mnt_is_readonly()
325 while (READ_ONCE(mnt->mnt.mnt_flags) & MNT_WRITE_HOLD) in __mnt_want_write()
468 mnt->mnt.mnt_flags |= MNT_WRITE_HOLD; in mnt_make_readonly()
494 mnt->mnt.mnt_flags |= MNT_READONLY; in mnt_make_readonly()
500 mnt->mnt.mnt_flags &= ~MNT_WRITE_HOLD; in mnt_make_readonly()
508 mnt->mnt.mnt_flags &= ~MNT_READONLY; in __mnt_unmake_readonly()
524 if (!(mnt->mnt.mnt_flags & MNT_READONLY)) { in sb_prepare_remount_readonly()
525 mnt->mnt.mnt_flags |= MNT_WRITE_HOLD; in sb_prepare_remount_readonly()
541 if (mnt->mnt.mnt_flags & MNT_WRITE_HOLD) in sb_prepare_remount_readonly()
542 mnt->mnt.mnt_flags &= ~MNT_WRITE_HOLD; in sb_prepare_remount_readonly()
576 if (bastard->mnt_flags & MNT_SYNC_UMOUNT) { in __legitimize_mnt()
581 if (unlikely(bastard->mnt_flags & MNT_DOOMED)) { in __legitimize_mnt()
664 return mnt->mnt.mnt_flags & MNT_CURSOR; in mnt_is_cursor()
962 mnt->mnt.mnt_flags = MNT_INTERNAL; in vfs_create_mount()
1055 mnt->mnt.mnt_flags = old->mnt.mnt_flags; in clone_mnt()
1056 mnt->mnt.mnt_flags &= ~(MNT_WRITE_HOLD|MNT_MARKED|MNT_INTERNAL); in clone_mnt()
1174 if (unlikely(mnt->mnt.mnt_flags & MNT_DOOMED)) { in mntput_no_expire()
1179 mnt->mnt.mnt_flags |= MNT_DOOMED; in mntput_no_expire()
1194 if (likely(!(mnt->mnt.mnt_flags & MNT_INTERNAL))) { in mntput_no_expire()
1263 p->mnt.mnt_flags |= MNT_INTERNAL; in mnt_clone_internal()
1462 if (!(mnt->mnt_parent->mnt.mnt_flags & MNT_UMOUNT)) in disconnect_mount()
1491 p->mnt.mnt_flags |= MNT_UMOUNT; in umount_tree()
1517 p->mnt.mnt_flags |= MNT_SYNC_UMOUNT; in umount_tree()
1633 if (mnt->mnt.mnt_flags & MNT_LOCKED) in do_umount()
1680 if (mnt->mnt.mnt_flags & MNT_UMOUNT) { in __detach_mounts()
1727 if (mnt->mnt.mnt_flags & MNT_LOCKED) /* Check optimistically */ in can_umount()
1841 if (s->mnt.mnt_flags & MNT_LOCKED) { in copy_tree()
1935 if (child->mnt.mnt_flags & MNT_LOCKED) in has_locked_children()
2002 int flags = p->mnt.mnt_flags; in lock_mnt_tree()
2020 p->mnt.mnt_flags = flags; in lock_mnt_tree()
2199 child->mnt.mnt_flags &= ~MNT_LOCKED; in attach_recursive_mnt()
2349 mnt->mnt.mnt_flags &= ~MNT_LOCKED; in __do_loopback()
2499 static bool can_change_locked_flags(struct mount *mnt, unsigned int mnt_flags) in can_change_locked_flags() argument
2501 unsigned int fl = mnt->mnt.mnt_flags; in can_change_locked_flags()
2504 !(mnt_flags & MNT_READONLY)) in can_change_locked_flags()
2508 !(mnt_flags & MNT_NODEV)) in can_change_locked_flags()
2512 !(mnt_flags & MNT_NOSUID)) in can_change_locked_flags()
2516 !(mnt_flags & MNT_NOEXEC)) in can_change_locked_flags()
2520 ((fl & MNT_ATIME_MASK) != (mnt_flags & MNT_ATIME_MASK))) in can_change_locked_flags()
2526 static int change_mount_ro_state(struct mount *mnt, unsigned int mnt_flags) in change_mount_ro_state() argument
2528 bool readonly_request = (mnt_flags & MNT_READONLY); in change_mount_ro_state()
2543 static void set_mount_attributes(struct mount *mnt, unsigned int mnt_flags) in set_mount_attributes() argument
2546 mnt_flags |= mnt->mnt.mnt_flags & ~MNT_USER_SETTABLE_MASK; in set_mount_attributes()
2547 mnt->mnt.mnt_flags = mnt_flags; in set_mount_attributes()
2579 static int do_reconfigure_mnt(struct path *path, unsigned int mnt_flags) in do_reconfigure_mnt() argument
2591 if (!can_change_locked_flags(mnt, mnt_flags)) in do_reconfigure_mnt()
2595 ret = change_mount_ro_state(mnt, mnt_flags); in do_reconfigure_mnt()
2597 set_mount_attributes(mnt, mnt_flags); in do_reconfigure_mnt()
2611 int mnt_flags, void *data) in do_remount() argument
2624 if (!can_change_locked_flags(mnt, mnt_flags)) in do_remount()
2639 set_mount_attributes(mnt, mnt_flags); in do_remount()
2716 if (old->mnt.mnt_flags & MNT_LOCKED) in do_move_mount()
2785 struct path *path, int mnt_flags) in do_add_mount() argument
2789 mnt_flags &= ~MNT_INTERNAL_FLAGS; in do_add_mount()
2793 if (!(mnt_flags & MNT_SHRINKABLE)) in do_add_mount()
2808 newmnt->mnt.mnt_flags = mnt_flags; in do_add_mount()
2819 unsigned int mnt_flags) in do_new_mount_fc() argument
2827 if (!error && mount_too_revealing(sb, &mnt_flags)) in do_new_mount_fc()
2848 error = do_add_mount(real_mount(mnt), mp, mountpoint, mnt_flags); in do_new_mount_fc()
2860 int mnt_flags, const char *name, void *data) in do_new_mount() argument
2902 err = do_new_mount_fc(fc, path, mnt_flags); in do_new_mount()
2956 err = do_add_mount(mnt, mp, path, path->mnt->mnt_flags | MNT_SHRINKABLE); in finish_automount()
3052 if (!(mnt->mnt.mnt_flags & MNT_SHRINKABLE)) in select_submounts()
3158 unsigned int mnt_flags = 0, sb_flags; in path_mount() local
3182 mnt_flags |= MNT_RELATIME; in path_mount()
3186 mnt_flags |= MNT_NOSUID; in path_mount()
3188 mnt_flags |= MNT_NODEV; in path_mount()
3190 mnt_flags |= MNT_NOEXEC; in path_mount()
3192 mnt_flags |= MNT_NOATIME; in path_mount()
3194 mnt_flags |= MNT_NODIRATIME; in path_mount()
3196 mnt_flags &= ~(MNT_RELATIME | MNT_NOATIME); in path_mount()
3198 mnt_flags |= MNT_READONLY; in path_mount()
3200 mnt_flags |= MNT_NOSYMFOLLOW; in path_mount()
3206 mnt_flags &= ~MNT_ATIME_MASK; in path_mount()
3207 mnt_flags |= path->mnt->mnt_flags & MNT_ATIME_MASK; in path_mount()
3220 return do_reconfigure_mnt(path, mnt_flags); in path_mount()
3222 return do_remount(path, flags, sb_flags, mnt_flags, data_page); in path_mount()
3230 return do_new_mount(path, type_page, sb_flags, mnt_flags, dev_name, in path_mount()
3475 unsigned int mnt_flags = 0; in SYSCALL_DEFINE3() local
3493 mnt_flags |= MNT_READONLY; in SYSCALL_DEFINE3()
3495 mnt_flags |= MNT_NOSUID; in SYSCALL_DEFINE3()
3497 mnt_flags |= MNT_NODEV; in SYSCALL_DEFINE3()
3499 mnt_flags |= MNT_NOEXEC; in SYSCALL_DEFINE3()
3501 mnt_flags |= MNT_NODIRATIME; in SYSCALL_DEFINE3()
3507 mnt_flags |= MNT_NOATIME; in SYSCALL_DEFINE3()
3510 mnt_flags |= MNT_RELATIME; in SYSCALL_DEFINE3()
3536 if (mount_too_revealing(fc->root->d_sb, &mnt_flags)) { in SYSCALL_DEFINE3()
3555 newmount.mnt->mnt_flags = mnt_flags; in SYSCALL_DEFINE3()
3753 if (new_mnt->mnt.mnt_flags & MNT_LOCKED) in SYSCALL_DEFINE2()
3779 if (root_mnt->mnt.mnt_flags & MNT_LOCKED) { in SYSCALL_DEFINE2()
3780 new_mnt->mnt.mnt_flags |= MNT_LOCKED; in SYSCALL_DEFINE2()
3781 root_mnt->mnt.mnt_flags &= ~MNT_LOCKED; in SYSCALL_DEFINE2()
3833 mnt->mnt_flags |= MNT_LOCKED; in init_mount_tree()
3962 int mnt_flags; in mnt_already_visible() local
3977 mnt_flags = mnt->mnt.mnt_flags; in mnt_already_visible()
3981 mnt_flags |= MNT_LOCK_READONLY; in mnt_already_visible()
3986 if ((mnt_flags & MNT_LOCK_READONLY) && in mnt_already_visible()
3989 if ((mnt_flags & MNT_LOCK_ATIME) && in mnt_already_visible()
3990 ((mnt_flags & MNT_ATIME_MASK) != (new_flags & MNT_ATIME_MASK))) in mnt_already_visible()
4000 if (!(child->mnt.mnt_flags & MNT_LOCKED)) in mnt_already_visible()
4007 *new_mnt_flags |= mnt_flags & (MNT_LOCK_READONLY | \ in mnt_already_visible()
4051 return !(mnt->mnt_flags & MNT_NOSUID) && check_mnt(real_mount(mnt)) && in mnt_may_suid()