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 9fdfd69..6ed35e2 100644 --- a/fs/ubifs/super.c +++ b/fs/ubifs/super.c @@ -1953,6 +1953,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; @@ -2019,6 +2020,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