]> git.baikalelectronics.ru Git - kernel.git/commit
f2fs: split discard command in prior to block layer
authorChao Yu <yuchao0@huawei.com>
Mon, 6 Aug 2018 14:43:50 +0000 (22:43 +0800)
committerJaegeuk Kim <jaegeuk@kernel.org>
Mon, 13 Aug 2018 17:48:17 +0000 (10:48 -0700)
commitabc61065776b194f85f39eefd1453ce963d6f9b6
tree0038876fb5399028e19155c391efe79cd5b994cb
parentf9840a5ce57768bb243141ff5ce42683374f0989
f2fs: split discard command in prior to block layer

Some devices has small max_{hw,}discard_sectors, so that in
__blkdev_issue_discard(), one big size discard bio can be split
into multiple small size discard bios, result in heavy load in IO
scheduler and device, which can hang other sync IO for long time.

Now, f2fs is trying to control discard commands more elaboratively,
in order to make less conflict in between discard IO and user IO
to enhance application's performance, so in this patch, we will
split discard bio in f2fs in prior to in block layer to reduce
issuing multiple discard bios in a short time.

Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/f2fs.h
fs/f2fs/segment.c