f2fs: fix to do sanity check for sb/cp fields correctly
authorChao Yu <chao@kernel.org>
Fri, 6 Aug 2021 00:04:37 +0000 (08:04 +0800)
committerJaegeuk Kim <jaegeuk@kernel.org>
Fri, 6 Aug 2021 00:17:07 +0000 (17:17 -0700)
commit65ddf6564843890a58ee3b18bb46ce67d96333fb
treedc7bfcc87a08dfc72c13878c4b3902c88cbe8fbf
parent4b10651864429386ae931167d3518f37a8c762e0
f2fs: fix to do sanity check for sb/cp fields correctly

This patch fixes below problems of sb/cp sanity check:
- in sanity_check_raw_superi(), it missed to consider log header
blocks while cp_payload check.
- in f2fs_sanity_check_ckpt(), it missed to check nat_bits_blocks.

Cc: <stable@kernel.org>
Signed-off-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/super.c