summaryrefslogtreecommitdiffstats
path: root/fs/f2fs/data.c
diff options
context:
space:
mode:
authorJaegeuk Kim <jaegeuk@kernel.org>2016-07-13 19:33:19 -0700
committerJaegeuk Kim <jaegeuk@kernel.org>2016-07-15 15:21:23 -0700
commit9dfa1baff76d08843aaf5e3c78f6da6950957702 (patch)
tree72de844844bf3a78ed02ba11e36b405246bf8a0d /fs/f2fs/data.c
parent82e0a5aa5ddf794b3e1b21fcd091228736871882 (diff)
downloadop-kernel-dev-9dfa1baff76d08843aaf5e3c78f6da6950957702.zip
op-kernel-dev-9dfa1baff76d08843aaf5e3c78f6da6950957702.tar.gz
f2fs: use blk_plug in all the possible paths
This patch reverts 19a5f5e2ef37 (f2fs: drop any block plugging), and adds blk_plug in write paths additionally. The main reason is that blk_start_plug can be used to wake up from low-power mode before submitting further bios. Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/data.c')
-rw-r--r--fs/f2fs/data.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/f2fs/data.c b/fs/f2fs/data.c
index adfe47b..87a458f 100644
--- a/fs/f2fs/data.c
+++ b/fs/f2fs/data.c
@@ -1438,6 +1438,7 @@ static int f2fs_write_data_pages(struct address_space *mapping,
{
struct inode *inode = mapping->host;
struct f2fs_sb_info *sbi = F2FS_I_SB(inode);
+ struct blk_plug plug;
int ret;
/* deal with chardevs and other special file */
@@ -1463,7 +1464,9 @@ static int f2fs_write_data_pages(struct address_space *mapping,
trace_f2fs_writepages(mapping->host, wbc, DATA);
+ blk_start_plug(&plug);
ret = f2fs_write_cache_pages(mapping, wbc);
+ blk_finish_plug(&plug);
/*
* if some pages were truncated, we cannot guarantee its mapping->host
* to detect pending bios.
OpenPOWER on IntegriCloud