]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
f2fs: call internal __write_data_page directly
authorJaegeuk Kim <jaegeuk@kernel.org>
Sat, 4 Feb 2017 01:18:00 +0000 (17:18 -0800)
committerJaegeuk Kim <jaegeuk@kernel.org>
Thu, 23 Feb 2017 18:10:46 +0000 (10:10 -0800)
This patch introduces __write_data_page to call it by f2fs_write_cache_pages
directly..

Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/data.c

index 3b5f1d14cab370df1362f9b302cf558d59405f67..e78286ee3cc7e35676ee51cb295bc2160c85518e 100644 (file)
@@ -1346,7 +1346,7 @@ int do_write_data_page(struct f2fs_io_info *fio)
        return err;
 }
 
-static int f2fs_write_data_page(struct page *page,
+static int __write_data_page(struct page *page,
                                        struct writeback_control *wbc)
 {
        struct inode *inode = page->mapping->host;
@@ -1448,6 +1448,12 @@ static int f2fs_write_data_page(struct page *page,
        return err;
 }
 
+static int f2fs_write_data_page(struct page *page,
+                                       struct writeback_control *wbc)
+{
+       return __write_data_page(page, wbc);
+}
+
 /*
  * This function was copied from write_cche_pages from mm/page-writeback.c.
  * The major change is making write step of cold data page separately from
@@ -1537,7 +1543,7 @@ static int f2fs_write_cache_pages(struct address_space *mapping,
                        if (!clear_page_dirty_for_io(page))
                                goto continue_unlock;
 
-                       ret = mapping->a_ops->writepage(page, wbc);
+                       ret = __write_data_page(page, wbc);
                        if (unlikely(ret)) {
                                /*
                                 * keep nr_to_write, since vfs uses this to