From 05ca3632e5a73b493b27ec3e2a337885563abff0 Mon Sep 17 00:00:00 2001 From: Jaegeuk Kim Date: Thu, 23 Apr 2015 14:38:15 -0700 Subject: f2fs: add sbi and page pointer in f2fs_io_info This patch adds f2fs_sb_info and page pointers in f2fs_io_info structure. With this change, we can reduce a lot of parameters for IO functions. Signed-off-by: Jaegeuk Kim --- fs/f2fs/gc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'fs/f2fs/gc.c') diff --git a/fs/f2fs/gc.c b/fs/f2fs/gc.c index ed58211fe79b..72667a54ac5f 100644 --- a/fs/f2fs/gc.c +++ b/fs/f2fs/gc.c @@ -521,8 +521,10 @@ static int check_dnode(struct f2fs_sb_info *sbi, struct f2fs_summary *sum, static void move_data_page(struct inode *inode, struct page *page, int gc_type) { struct f2fs_io_info fio = { + .sbi = F2FS_I_SB(inode), .type = DATA, .rw = WRITE_SYNC, + .page = page, }; if (gc_type == BG_GC) { @@ -536,7 +538,7 @@ static void move_data_page(struct inode *inode, struct page *page, int gc_type) if (clear_page_dirty_for_io(page)) inode_dec_dirty_pages(inode); set_cold_data(page); - do_write_data_page(page, &fio); + do_write_data_page(&fio); clear_cold_data(page); } out: -- cgit v1.2.3