Skip to content

Commit

Permalink
vfs: Undo an overly zealous MS_RDONLY -> SB_RDONLY conversion
Browse files Browse the repository at this point in the history
In do_mount() when the MS_* flags are being converted to MNT_* flags,
MS_RDONLY got accidentally convered to SB_RDONLY.

Undo this change.

Fixes: e462ec5 ("VFS: Differentiate mount flags (MS_*) from internal superblock flags")
Signed-off-by: David Howells <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
dhowells authored and torvalds committed Apr 20, 2018
1 parent 6606259 commit a9e5b73
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fs/namespace.c
Original file line number Diff line number Diff line change
Expand Up @@ -2815,7 +2815,7 @@ long do_mount(const char *dev_name, const char __user *dir_name,
mnt_flags |= MNT_NODIRATIME;
if (flags & MS_STRICTATIME)
mnt_flags &= ~(MNT_RELATIME | MNT_NOATIME);
if (flags & SB_RDONLY)
if (flags & MS_RDONLY)
mnt_flags |= MNT_READONLY;

/* The default atime for remount is preservation */
Expand Down

0 comments on commit a9e5b73

Please sign in to comment.