From 406657dd1868a4d7b12be04ed769d9215ec9a7d1 Mon Sep 17 00:00:00 2001 From: Chao Yu Date: Wed, 24 Feb 2016 17:17:55 +0800 Subject: 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 Signed-off-by: Jaegeuk Kim --- fs/f2fs/data.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'fs/f2fs/data.c') diff --git a/fs/f2fs/data.c b/fs/f2fs/data.c index cc5ce9f..9643d88 100644 --- a/fs/f2fs/data.c +++ b/fs/f2fs/data.c @@ -206,6 +206,13 @@ void f2fs_submit_merged_bio_cond(struct f2fs_sb_info *sbi, __f2fs_submit_merged_bio(sbi, inode, page, ino, type, rw); } +void f2fs_flush_merged_bios(struct f2fs_sb_info *sbi) +{ + f2fs_submit_merged_bio(sbi, DATA, WRITE); + f2fs_submit_merged_bio(sbi, NODE, WRITE); + f2fs_submit_merged_bio(sbi, META, WRITE); +} + /* * Fill the locked page with data located in the block address. * Return unlocked page. -- cgit v1.1