diff options
| -rw-r--r-- | fs/namespace.c | 2 | ||||
| -rw-r--r-- | include/linux/mount.h | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/fs/namespace.c b/fs/namespace.c index 7187d01329c3..cb40449ea0df 100644 --- a/fs/namespace.c +++ b/fs/namespace.c | |||
| @@ -1937,7 +1937,7 @@ static int do_remount(struct path *path, int flags, int mnt_flags, | |||
| 1937 | err = do_remount_sb(sb, flags, data, 0); | 1937 | err = do_remount_sb(sb, flags, data, 0); |
| 1938 | if (!err) { | 1938 | if (!err) { |
| 1939 | lock_mount_hash(); | 1939 | lock_mount_hash(); |
| 1940 | mnt_flags |= mnt->mnt.mnt_flags & MNT_PROPAGATION_MASK; | 1940 | mnt_flags |= mnt->mnt.mnt_flags & ~MNT_USER_SETTABLE_MASK; |
| 1941 | mnt->mnt.mnt_flags = mnt_flags; | 1941 | mnt->mnt.mnt_flags = mnt_flags; |
| 1942 | touch_mnt_namespace(mnt->mnt_ns); | 1942 | touch_mnt_namespace(mnt->mnt_ns); |
| 1943 | unlock_mount_hash(); | 1943 | unlock_mount_hash(); |
diff --git a/include/linux/mount.h b/include/linux/mount.h index 839bac270904..b637a89e1fae 100644 --- a/include/linux/mount.h +++ b/include/linux/mount.h | |||
| @@ -42,7 +42,9 @@ struct mnt_namespace; | |||
| 42 | * flag, consider how it interacts with shared mounts. | 42 | * flag, consider how it interacts with shared mounts. |
| 43 | */ | 43 | */ |
| 44 | #define MNT_SHARED_MASK (MNT_UNBINDABLE) | 44 | #define MNT_SHARED_MASK (MNT_UNBINDABLE) |
| 45 | #define MNT_PROPAGATION_MASK (MNT_SHARED | MNT_UNBINDABLE) | 45 | #define MNT_USER_SETTABLE_MASK (MNT_NOSUID | MNT_NODEV | MNT_NOEXEC \ |
| 46 | | MNT_NOATIME | MNT_NODIRATIME | MNT_RELATIME \ | ||
| 47 | | MNT_READONLY) | ||
| 46 | 48 | ||
| 47 | #define MNT_INTERNAL_FLAGS (MNT_SHARED | MNT_WRITE_HOLD | MNT_INTERNAL | \ | 49 | #define MNT_INTERNAL_FLAGS (MNT_SHARED | MNT_WRITE_HOLD | MNT_INTERNAL | \ |
| 48 | MNT_DOOMED | MNT_SYNC_UMOUNT | MNT_MARKED) | 50 | MNT_DOOMED | MNT_SYNC_UMOUNT | MNT_MARKED) |
