diff options
author | Jaegeuk Kim <jaegeuk@kernel.org> | 2016-07-14 05:33:19 +0300 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2016-07-16 01:21:23 +0300 |
commit | 9dfa1baff76d08843aaf5e3c78f6da6950957702 (patch) | |
tree | 72de844844bf3a78ed02ba11e36b405246bf8a0d /fs/f2fs/node.c | |
parent | 82e0a5aa5ddf794b3e1b21fcd091228736871882 (diff) | |
download | linux-9dfa1baff76d08843aaf5e3c78f6da6950957702.tar.xz |
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/node.c')
-rw-r--r-- | fs/f2fs/node.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/f2fs/node.c b/fs/f2fs/node.c index d78f61d647c0..79a93c6e632f 100644 --- a/fs/f2fs/node.c +++ b/fs/f2fs/node.c @@ -1618,6 +1618,7 @@ static int f2fs_write_node_pages(struct address_space *mapping, struct writeback_control *wbc) { struct f2fs_sb_info *sbi = F2FS_M_SB(mapping); + struct blk_plug plug; long diff; /* balancing f2fs's metadata in background */ @@ -1631,7 +1632,9 @@ static int f2fs_write_node_pages(struct address_space *mapping, diff = nr_pages_to_write(sbi, NODE, wbc); wbc->sync_mode = WB_SYNC_NONE; + blk_start_plug(&plug); sync_node_pages(sbi, wbc); + blk_finish_plug(&plug); wbc->nr_to_write = max((long)0, wbc->nr_to_write - diff); return 0; |