We need to set or clear MS_RDONLY in remounting. Signed-off-by: Dongsheng Yang <yangds.fnst@xxxxxxxxxxxxxx> --- fs/ubifs/super.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fs/ubifs/super.c b/fs/ubifs/super.c index 2b07709..59cdfc2 100644 --- a/fs/ubifs/super.c +++ b/fs/ubifs/super.c @@ -1840,6 +1840,7 @@ static int ubifs_remount_rw(struct ubifs_info *c) */ err = dbg_check_space_info(c); } + c->vfs_sb->s_flags &= ~MS_RDONLY; mutex_unlock(&c->umount_mutex); return err; @@ -1906,6 +1907,7 @@ static void ubifs_remount_ro(struct ubifs_info *c) err = dbg_check_space_info(c); if (err) ubifs_ro_mode(c, err); + c->vfs_sb->s_flags |= MS_RDONLY; mutex_unlock(&c->umount_mutex); } -- 1.8.4.2 -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html