diff options
author | Chao Yu <yuchao0@huawei.com> | 2018-03-01 16:40:31 +0100 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2018-03-17 05:57:26 +0100 |
commit | deeedd71e3732fb72740eb41cf66214b2b13005e (patch) | |
tree | e11f8a07ceb0a43a7a743c0a4b3cbedb4552d9a7 /fs/f2fs/super.c | |
parent | f2fs: avoid selinux denial on CAP_SYS_RESOURCE (diff) | |
download | linux-deeedd71e3732fb72740eb41cf66214b2b13005e.tar.xz linux-deeedd71e3732fb72740eb41cf66214b2b13005e.zip |
f2fs: wrap sb_rdonly with f2fs_readonly
Use f2fs_readonly to wrap sb_rdonly for cleanup, and spread it in
all places.
Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/super.c')
-rw-r--r-- | fs/f2fs/super.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c index 30b93ad44b9d..d8357ba19159 100644 --- a/fs/f2fs/super.c +++ b/fs/f2fs/super.c @@ -336,7 +336,7 @@ static int f2fs_check_quota_options(struct f2fs_sb_info *sbi) "QUOTA feature is enabled, so ignore jquota_fmt"); sbi->s_jquota_fmt = 0; } - if (f2fs_sb_has_quota_ino(sbi->sb) && sb_rdonly(sbi->sb)) { + if (f2fs_sb_has_quota_ino(sbi->sb) && f2fs_readonly(sbi->sb)) { f2fs_msg(sbi->sb, KERN_INFO, "Filesystem with quota feature cannot be mounted RDWR " "without CONFIG_QUOTA"); @@ -2805,7 +2805,7 @@ try_onemore: * Turn on quotas which were not enabled for read-only mounts if * filesystem has quota feature, so that they are updated correctly. */ - if (f2fs_sb_has_quota_ino(sb) && !sb_rdonly(sb)) { + if (f2fs_sb_has_quota_ino(sb) && !f2fs_readonly(sb)) { err = f2fs_enable_quotas(sb); if (err) { f2fs_msg(sb, KERN_ERR, @@ -2890,7 +2890,7 @@ skip_recovery: free_meta: #ifdef CONFIG_QUOTA - if (f2fs_sb_has_quota_ino(sb) && !sb_rdonly(sb)) + if (f2fs_sb_has_quota_ino(sb) && !f2fs_readonly(sb)) f2fs_quota_off_umount(sbi->sb); #endif f2fs_sync_inode_meta(sbi); |