summaryrefslogtreecommitdiffstats
path: root/fs/erofs/super.c
diff options
context:
space:
mode:
authorGao Xiang <hsiangkao@redhat.com>2021-03-29 09:23:05 +0800
committerGao Xiang <hsiangkao@redhat.com>2021-03-29 10:24:57 +0800
commitde06a6a375414be03ce5b1054f2d836591923a1d (patch)
tree8db8685441b4a9a5d712c5679839de2388844077 /fs/erofs/super.c
parent24a806d849c0b0c1d0cd6a6b93ba4ae4c0ec9f08 (diff)
downloadlinux-de06a6a375414be03ce5b1054f2d836591923a1d.tar.bz2
erofs: introduce erofs_sb_has_xxx() helpers
Introduce erofs_sb_has_xxx() to make long checks short, especially for later big pcluster & LZMA features. Link: https://lore.kernel.org/r/20210329012308.28743-2-hsiangkao@aol.com Reviewed-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Gao Xiang <hsiangkao@redhat.com>
Diffstat (limited to 'fs/erofs/super.c')
-rw-r--r--fs/erofs/super.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/erofs/super.c b/fs/erofs/super.c
index 0445d09b6331..991b99eaf22a 100644
--- a/fs/erofs/super.c
+++ b/fs/erofs/super.c
@@ -149,7 +149,7 @@ static int erofs_read_superblock(struct super_block *sb)
}
sbi->feature_compat = le32_to_cpu(dsb->feature_compat);
- if (sbi->feature_compat & EROFS_FEATURE_COMPAT_SB_CHKSUM) {
+ if (erofs_sb_has_sb_chksum(sbi)) {
ret = erofs_superblock_csum_verify(sb, data);
if (ret)
goto out;