mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-11 12:44:49 -04:00
f2fs: avoid gc in cp_error case
Otherwise, we can hit f2fs_bug_on(sbi, !PageUptodate(sum_page)); Reviewed-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
This commit is contained in:
@@ -847,7 +847,8 @@ static int do_garbage_collect(struct f2fs_sb_info *sbi,
|
||||
|
||||
for (segno = start_segno; segno < end_segno; segno++) {
|
||||
|
||||
if (get_valid_blocks(sbi, segno, 1) == 0)
|
||||
if (get_valid_blocks(sbi, segno, 1) == 0 ||
|
||||
unlikely(f2fs_cp_error(sbi)))
|
||||
goto next;
|
||||
|
||||
/* find segment summary of victim */
|
||||
|
||||
Reference in New Issue
Block a user