summaryrefslogtreecommitdiff
path: root/fs/f2fs/super.c
diff options
context:
space:
mode:
authorChao Yu <chao2.yu@samsung.com>2016-02-24 17:17:55 +0800
committerJaegeuk Kim <jaegeuk@kernel.org>2016-02-26 11:52:02 -0800
commit406657dd1868a4d7b12be04ed769d9215ec9a7d1 (patch)
tree737fb58c96b15273c559cbf077fce80dd477f771 /fs/f2fs/super.c
parentf28b3434afb8bb586965970039e46ffb6a1be033 (diff)
f2fs: introduce f2fs_flush_merged_bios for cleanup
Add a new helper f2fs_flush_merged_bios to clean up redundant codes. Signed-off-by: Chao Yu <chao2.yu@samsung.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/super.c')
-rw-r--r--fs/f2fs/super.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c
index 2a5fc08b4ec7..579372d9291f 100644
--- a/fs/f2fs/super.c
+++ b/fs/f2fs/super.c
@@ -583,11 +583,8 @@ static void f2fs_put_super(struct super_block *sb)
mutex_unlock(&sbi->umount_mutex);
/* our cp_error case, we can wait for any writeback page */
- if (get_pages(sbi, F2FS_WRITEBACK)) {
- f2fs_submit_merged_bio(sbi, DATA, WRITE);
- f2fs_submit_merged_bio(sbi, NODE, WRITE);
- f2fs_submit_merged_bio(sbi, META, WRITE);
- }
+ if (get_pages(sbi, F2FS_WRITEBACK))
+ f2fs_flush_merged_bios(sbi);
iput(sbi->node_inode);
iput(sbi->meta_inode);