summaryrefslogtreecommitdiff
path: root/fs/nilfs2/recovery.c
diff options
context:
space:
mode:
authorMatthew Wilcox (Oracle) <willy@infradead.org>2024-07-15 14:24:01 -0400
committerChristian Brauner <brauner@kernel.org>2024-08-07 11:33:21 +0200
commit1da86618bdce301d23e89ecce92161f9d3b3c5e7 (patch)
tree7e6d452f81d12f8b472b0a037f0d5654ea18766b /fs/nilfs2/recovery.c
parenta225800f322a3d6cc8b8b6c7dc4d5281f2f5375b (diff)
fs: Convert aops->write_begin to take a folio
Convert all callers from working on a page to working on one page of a folio (support for working on an entire folio can come later). Removes a lot of folio->page->folio conversions. Reviewed-by: Josef Bacik <josef@toxicpanda.com> Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> Signed-off-by: Christian Brauner <brauner@kernel.org>
Diffstat (limited to 'fs/nilfs2/recovery.c')
-rw-r--r--fs/nilfs2/recovery.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/fs/nilfs2/recovery.c b/fs/nilfs2/recovery.c
index 40c5dfbc9d41..c2e60a6bd060 100644
--- a/fs/nilfs2/recovery.c
+++ b/fs/nilfs2/recovery.c
@@ -498,7 +498,6 @@ static int nilfs_recover_dsync_blocks(struct the_nilfs *nilfs,
struct inode *inode;
struct nilfs_recovery_block *rb, *n;
unsigned int blocksize = nilfs->ns_blocksize;
- struct page *page;
struct folio *folio;
loff_t pos;
int err = 0, err2 = 0;
@@ -513,7 +512,7 @@ static int nilfs_recover_dsync_blocks(struct the_nilfs *nilfs,
pos = rb->blkoff << inode->i_blkbits;
err = block_write_begin(inode->i_mapping, pos, blocksize,
- &page, nilfs_get_block);
+ &folio, nilfs_get_block);
if (unlikely(err)) {
loff_t isize = inode->i_size;
@@ -523,8 +522,7 @@ static int nilfs_recover_dsync_blocks(struct the_nilfs *nilfs,
goto failed_inode;
}
- folio = page_folio(page);
- err = nilfs_recovery_copy_block(nilfs, rb, pos, page);
+ err = nilfs_recovery_copy_block(nilfs, rb, pos, &folio->page);
if (unlikely(err))
goto failed_page;