From: Jaegeuk Kim Date: Wed, 21 Dec 2016 19:51:32 +0000 (-0800) Subject: f2fs: reassign new segment for mode=lfs X-Git-Tag: v5.15~11759^2~89 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9d52a504db6db9e4e254576130aa867838daff55;p=platform%2Fkernel%2Flinux-starfive.git f2fs: reassign new segment for mode=lfs Otherwise we can remain wrong curseg->next_blkoff, resulting in fsck failure. Signed-off-by: Jaegeuk Kim --- diff --git a/fs/f2fs/segment.c b/fs/f2fs/segment.c index cf98ba7b..b6bb649 100644 --- a/fs/f2fs/segment.c +++ b/fs/f2fs/segment.c @@ -1428,9 +1428,6 @@ void allocate_new_segments(struct f2fs_sb_info *sbi) unsigned int old_segno; int i; - if (test_opt(sbi, LFS)) - return; - for (i = CURSEG_HOT_DATA; i <= CURSEG_COLD_DATA; i++) { curseg = CURSEG_I(sbi, i); old_segno = curseg->segno;