summaryrefslogtreecommitdiffstats
path: root/fs/f2fs/segment.c
diff options
context:
space:
mode:
authorChao Yu <yuchao0@huawei.com>2018-04-10 09:43:09 +0200
committerJaegeuk Kim <jaegeuk@kernel.org>2018-05-30 17:58:59 +0200
commitcba608493d3d5d54da4b7dd67868f88c43dfbd35 (patch)
tree85bb8f3287d4236c1602d7b58452ad1280c8e309 /fs/f2fs/segment.c
parentf2fs: don't split checkpoint in fstrim (diff)
downloadlinux-cba608493d3d5d54da4b7dd67868f88c43dfbd35.tar.xz
linux-cba608493d3d5d54da4b7dd67868f88c43dfbd35.zip
f2fs: turn down IO priority of discard from background
In order to avoid interfering normal r/w IO, let's turn down IO priority of discard issued from background. Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/segment.c')
-rw-r--r--fs/f2fs/segment.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/f2fs/segment.c b/fs/f2fs/segment.c
index 3db035bf7203..bef74d628f66 100644
--- a/fs/f2fs/segment.c
+++ b/fs/f2fs/segment.c
@@ -931,6 +931,7 @@ static void __init_discard_policy(struct f2fs_sb_info *sbi,
dpolicy->min_interval = DEF_MIN_DISCARD_ISSUE_TIME;
dpolicy->max_interval = DEF_MAX_DISCARD_ISSUE_TIME;
dpolicy->io_aware = true;
+ dpolicy->sync = false;
if (utilization(sbi) > DEF_DISCARD_URGENT_UTIL) {
dpolicy->granularity = 1;
dpolicy->max_interval = DEF_MIN_DISCARD_ISSUE_TIME;