fsck.f2fs: do not check the first seg in a sec in find_next_free_block
The first segment is already checked, so there is no need to check it
again if we want to make sure the whole section is freed.
Signed-off-by: Sheng Yong <shengyong1@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
diff --git a/fsck/mount.c b/fsck/mount.c
index ca7f6dd..0a47bf7 100644
--- a/fsck/mount.c
+++ b/fsck/mount.c
@@ -1573,7 +1573,7 @@
struct seg_entry *se2;
unsigned int i;
- for (i = 0; i < sbi->segs_per_sec; i++) {
+ for (i = 1; i < sbi->segs_per_sec; i++) {
se2 = get_seg_entry(sbi, segno + i);
if (se2->valid_blocks)
break;