f2fs: add GC_URGENT_LOW mode in gc_urgent
Added a new gc_urgent mode, GC_URGENT_LOW, in which mode F2FS will lower the bar of checking idle in order to process outstanding discard commands and GC a little bit aggressively. Signed-off-by: Daeho Jeong <daehojeong@google.com> Reviewed-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
This commit is contained in:
@@ -174,7 +174,7 @@ bool f2fs_need_SSR(struct f2fs_sb_info *sbi)
|
||||
|
||||
if (f2fs_lfs_mode(sbi))
|
||||
return false;
|
||||
if (sbi->gc_mode == GC_URGENT)
|
||||
if (sbi->gc_mode == GC_URGENT_HIGH)
|
||||
return true;
|
||||
if (unlikely(is_sbi_flag_set(sbi, SBI_CP_DISABLED)))
|
||||
return true;
|
||||
@@ -1759,7 +1759,7 @@ static int issue_discard_thread(void *data)
|
||||
continue;
|
||||
}
|
||||
|
||||
if (sbi->gc_mode == GC_URGENT)
|
||||
if (sbi->gc_mode == GC_URGENT_HIGH)
|
||||
__init_discard_policy(sbi, &dpolicy, DPOLICY_FORCE, 1);
|
||||
|
||||
sb_start_intwrite(sbi->sb);
|
||||
|
Reference in New Issue
Block a user