summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fs/f2fs/gc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/f2fs/gc.c b/fs/f2fs/gc.c
index 9b5d0aad5daf..fb03be68cb20 100644
--- a/fs/f2fs/gc.c
+++ b/fs/f2fs/gc.c
@@ -672,7 +672,7 @@ gc_more:
if (!(sbi->sb->s_flags & MS_ACTIVE))
goto stop;
- if (has_not_enough_free_secs(sbi))
+ if (gc_type == BG_GC && has_not_enough_free_secs(sbi))
gc_type = FG_GC;
if (!__get_victim(sbi, &segno, gc_type, NO_CHECK_TYPE))