f2fs: set ioprio of GC kthread to idle
GC should run conservatively as possible to reduce latency spikes to the user. Setting ioprio to idle class will allow the kernel to schedule GC thread's I/O to not affect any other processes' I/O requests. Signed-off-by: Park Ju Hyung <qkrwngud825@gmail.com> Signed-off-by: Danny Lin <danny@kdrag0n.dev>
This commit is contained in:
parent
f64ba4724c
commit
78e3f5a4b3
@ -195,7 +195,9 @@ int f2fs_start_gc_thread(struct f2fs_sb_info *sbi)
|
|||||||
sbi->gc_thread = NULL;
|
sbi->gc_thread = NULL;
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
|
set_task_ioprio(sbi->gc_thread->f2fs_gc_task,
|
||||||
|
IOPRIO_PRIO_VALUE(IOPRIO_CLASS_IDLE, 0));
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user