Resize rebuilds checkpoint with 6 summary blocks, so if
CP_COMPACT_SUM_FLAG is set in the old checkpoint, clear it.

Signed-off-by: Sheng Yong <shengyo...@huawei.com>
---
 fsck/resize.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/fsck/resize.c b/fsck/resize.c
index 7643511..019da71 100644
--- a/fsck/resize.c
+++ b/fsck/resize.c
@@ -504,6 +504,8 @@ static void rebuild_checkpoint(struct f2fs_sb_info *sbi,
 
        /* update nat_bits flag */
        flags = update_nat_bits_flags(new_sb, cp, get_cp(ckpt_flags));
+       if (flags & CP_COMPACT_SUM_FLAG)
+               flags &= ~CP_COMPACT_SUM_FLAG;
        set_cp(ckpt_flags, flags);
 
        memcpy(new_cp, cp, (unsigned char *)cp->sit_nat_version_bitmap -
-- 
2.14.1


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Reply via email to