fs: Convert block_read_full_page() to block_read_full_folio()
[linux-2.6-block.git] / fs / reiserfs / inode.c
index 36c59b25486c8726c496629b487ab07b4bc8701b..33a9555f77b9addc401d4baedc4c9b24124c931f 100644 (file)
@@ -167,10 +167,10 @@ inline void make_le_item_head(struct item_head *ih, const struct cpu_key *key,
  * cutting the code is fine, since it really isn't in use yet and is easy
  * to add back in.  But, Vladimir has a really good idea here.  Think
  * about what happens for reading a file.  For each page,
- * The VFS layer calls reiserfs_readpage, who searches the tree to find
+ * The VFS layer calls reiserfs_read_folio, who searches the tree to find
  * an indirect item.  This indirect item has X number of pointers, where
  * X is a big number if we've done the block allocation right.  But,
- * we only use one or two of these pointers during each call to readpage,
+ * we only use one or two of these pointers during each call to read_folio,
  * needlessly researching again later on.
  *
  * The size of the cache could be dynamic based on the size of the file.
@@ -966,7 +966,7 @@ research:
                         * it is important the set_buffer_uptodate is done
                         * after the direct2indirect.  The buffer might
                         * contain valid data newer than the data on disk
-                        * (read by readpage, changed, and then sent here by
+                        * (read by read_folio, changed, and then sent here by
                         * writepage).  direct2indirect needs to know if unbh
                         * was already up to date, so it can decide if the
                         * data in unbh needs to be replaced with data from
@@ -2733,9 +2733,9 @@ fail:
        goto done;
 }
 
-static int reiserfs_readpage(struct file *f, struct page *page)
+static int reiserfs_read_folio(struct file *f, struct folio *folio)
 {
-       return block_read_full_page(page, reiserfs_get_block);
+       return block_read_full_folio(folio, reiserfs_get_block);
 }
 
 static int reiserfs_writepage(struct page *page, struct writeback_control *wbc)
@@ -2753,7 +2753,7 @@ static void reiserfs_truncate_failed_write(struct inode *inode)
 
 static int reiserfs_write_begin(struct file *file,
                                struct address_space *mapping,
-                               loff_t pos, unsigned len, unsigned flags,
+                               loff_t pos, unsigned len,
                                struct page **pagep, void **fsdata)
 {
        struct inode *inode;
@@ -2764,7 +2764,7 @@ static int reiserfs_write_begin(struct file *file,
 
        inode = mapping->host;
        index = pos >> PAGE_SHIFT;
-       page = grab_cache_page_write_begin(mapping, index, flags);
+       page = grab_cache_page_write_begin(mapping, index);
        if (!page)
                return -ENOMEM;
        *pagep = page;
@@ -3421,7 +3421,7 @@ out:
 
 const struct address_space_operations reiserfs_address_space_operations = {
        .writepage = reiserfs_writepage,
-       .readpage = reiserfs_readpage,
+       .read_folio = reiserfs_read_folio,
        .readahead = reiserfs_readahead,
        .releasepage = reiserfs_releasepage,
        .invalidate_folio = reiserfs_invalidate_folio,