aboutsummaryrefslogtreecommitdiffstats
path: root/fs/namespace.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/namespace.c')
-rw-r--r--fs/namespace.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/fs/namespace.c b/fs/namespace.c
index b94325f00c5a..2dd333b0fe7f 100644
--- a/fs/namespace.c
+++ b/fs/namespace.c
@@ -1060,11 +1060,8 @@ static int do_umount(struct vfsmount *mnt, int flags)
1060 * we just try to remount it readonly. 1060 * we just try to remount it readonly.
1061 */ 1061 */
1062 down_write(&sb->s_umount); 1062 down_write(&sb->s_umount);
1063 if (!(sb->s_flags & MS_RDONLY)) { 1063 if (!(sb->s_flags & MS_RDONLY))
1064 lock_kernel();
1065 retval = do_remount_sb(sb, MS_RDONLY, NULL, 0); 1064 retval = do_remount_sb(sb, MS_RDONLY, NULL, 0);
1066 unlock_kernel();
1067 }
1068 up_write(&sb->s_umount); 1065 up_write(&sb->s_umount);
1069 return retval; 1066 return retval;
1070 } 1067 }
@@ -1515,11 +1512,8 @@ static int do_remount(struct path *path, int flags, int mnt_flags,
1515 down_write(&sb->s_umount); 1512 down_write(&sb->s_umount);
1516 if (flags & MS_BIND) 1513 if (flags & MS_BIND)
1517 err = change_mount_flags(path->mnt, flags); 1514 err = change_mount_flags(path->mnt, flags);
1518 else { 1515 else
1519 lock_kernel();
1520 err = do_remount_sb(sb, flags, data, 0); 1516 err = do_remount_sb(sb, flags, data, 0);
1521 unlock_kernel();
1522 }
1523 if (!err) 1517 if (!err)
1524 path->mnt->mnt_flags = mnt_flags; 1518 path->mnt->mnt_flags = mnt_flags;
1525 up_write(&sb->s_umount); 1519 up_write(&sb->s_umount);