fs/buffer.c: remove block_write_full_page_endio()
authorMatthew Wilcox <matthew.r.wilcox@intel.com>
Wed, 4 Jun 2014 23:07:43 +0000 (16:07 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 4 Jun 2014 23:54:02 +0000 (16:54 -0700)
The last in-tree caller of block_write_full_page_endio() was removed in
January 2013.  It's time to remove the EXPORT_SYMBOL, which leaves
block_write_full_page() as the only caller of
block_write_full_page_endio(), so inline block_write_full_page_endio()
into block_write_full_page().

Signed-off-by: Matthew Wilcox <matthew.r.wilcox@intel.com>
Cc: Hugh Dickins <hughd@google.com>
Cc: Dave Chinner <david@fromorbit.com>
Cc: Dheeraj Reddy <dheeraj.reddy@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/buffer.c
fs/ext4/page-io.c
fs/ocfs2/file.c
include/linux/buffer_head.h

index 6a8110c03a4734c7efa0ad2e90ff22fe4b365485..e33f8d5452ad827eb873bdb6fa446b92ae1e0c61 100644 (file)
@@ -2879,10 +2879,9 @@ EXPORT_SYMBOL(block_truncate_page);
 
 /*
  * The generic ->writepage function for buffer-backed address_spaces
- * this form passes in the end_io handler used to finish the IO.
  */
-int block_write_full_page_endio(struct page *page, get_block_t *get_block,
-                       struct writeback_control *wbc, bh_end_io_t *handler)
+int block_write_full_page(struct page *page, get_block_t *get_block,
+                       struct writeback_control *wbc)
 {
        struct inode * const inode = page->mapping->host;
        loff_t i_size = i_size_read(inode);
@@ -2892,7 +2891,7 @@ int block_write_full_page_endio(struct page *page, get_block_t *get_block,
        /* Is the page fully inside i_size? */
        if (page->index < end_index)
                return __block_write_full_page(inode, page, get_block, wbc,
-                                              handler);
+                                              end_buffer_async_write);
 
        /* Is the page fully outside i_size? (truncate in progress) */
        offset = i_size & (PAGE_CACHE_SIZE-1);
@@ -2915,18 +2914,8 @@ int block_write_full_page_endio(struct page *page, get_block_t *get_block,
         * writes to that region are not written out to the file."
         */
        zero_user_segment(page, offset, PAGE_CACHE_SIZE);
-       return __block_write_full_page(inode, page, get_block, wbc, handler);
-}
-EXPORT_SYMBOL(block_write_full_page_endio);
-
-/*
- * The generic ->writepage function for buffer-backed address_spaces
- */
-int block_write_full_page(struct page *page, get_block_t *get_block,
-                       struct writeback_control *wbc)
-{
-       return block_write_full_page_endio(page, get_block, wbc,
-                                          end_buffer_async_write);
+       return __block_write_full_page(inode, page, get_block, wbc,
+                                                       end_buffer_async_write);
 }
 EXPORT_SYMBOL(block_write_full_page);
 
index c18d95b5054081c75e0c7a2fab975976838f9b02..1a64e7a52b841be24ddd3daa56cb47939f07656c 100644 (file)
@@ -429,7 +429,7 @@ int ext4_bio_write_page(struct ext4_io_submit *io,
                block_start = bh_offset(bh);
                if (block_start >= len) {
                        /*
-                        * Comments copied from block_write_full_page_endio:
+                        * Comments copied from block_write_full_page:
                         *
                         * The page straddles i_size.  It must be zeroed out on
                         * each and every writepage invocation because it may
index 8970dcf74de53e71539e8fad7042a55f66a2c713..8eb6e5732d3b73b115abea0681cdd95d9195becf 100644 (file)
@@ -828,7 +828,7 @@ static int ocfs2_write_zero_page(struct inode *inode, u64 abs_from,
                /*
                 * fs-writeback will release the dirty pages without page lock
                 * whose offset are over inode size, the release happens at
-                * block_write_full_page_endio().
+                * block_write_full_page().
                 */
                i_size_write(inode, abs_to);
                inode->i_blocks = ocfs2_inode_sector_count(inode);
index 7cbf837a279c02f12baac4241a93e5786f3b3547..324329ceea1e89c48b8170f8886e4b0c88066e91 100644 (file)
@@ -207,8 +207,6 @@ void block_invalidatepage(struct page *page, unsigned int offset,
                          unsigned int length);
 int block_write_full_page(struct page *page, get_block_t *get_block,
                                struct writeback_control *wbc);
-int block_write_full_page_endio(struct page *page, get_block_t *get_block,
-                       struct writeback_control *wbc, bh_end_io_t *handler);
 int block_read_full_page(struct page*, get_block_t*);
 int block_is_partially_uptodate(struct page *page, unsigned long from,
                                unsigned long count);