mirror of
https://github.com/torvalds/linux.git
synced 2026-05-28 17:13:52 +02:00
f2fs: Pass a folio to recover_inode()
The only caller has a folio, so pass it in. Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> Reviewed-by: Chao Yu <chao@kernel.org> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
This commit is contained in:
parent
9050cabbe1
commit
7872c71e64
|
|
@ -277,16 +277,16 @@ static void recover_inline_flags(struct inode *inode, struct f2fs_inode *ri)
|
|||
clear_inode_flag(inode, FI_DATA_EXIST);
|
||||
}
|
||||
|
||||
static int recover_inode(struct inode *inode, struct page *page)
|
||||
static int recover_inode(struct inode *inode, struct folio *folio)
|
||||
{
|
||||
struct f2fs_inode *raw = F2FS_INODE(page);
|
||||
struct f2fs_inode *raw = F2FS_INODE(&folio->page);
|
||||
struct f2fs_inode_info *fi = F2FS_I(inode);
|
||||
char *name;
|
||||
int err;
|
||||
|
||||
inode->i_mode = le16_to_cpu(raw->i_mode);
|
||||
|
||||
err = recover_quota_data(inode, page);
|
||||
err = recover_quota_data(inode, &folio->page);
|
||||
if (err)
|
||||
return err;
|
||||
|
||||
|
|
@ -333,10 +333,10 @@ static int recover_inode(struct inode *inode, struct page *page)
|
|||
if (file_enc_name(inode))
|
||||
name = "<encrypted>";
|
||||
else
|
||||
name = F2FS_INODE(page)->i_name;
|
||||
name = F2FS_INODE(&folio->page)->i_name;
|
||||
|
||||
f2fs_notice(F2FS_I_SB(inode), "recover_inode: ino = %x, name = %s, inline = %x",
|
||||
ino_of_node(page), name, raw->i_inline);
|
||||
ino_of_node(&folio->page), name, raw->i_inline);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -822,7 +822,7 @@ static int recover_data(struct f2fs_sb_info *sbi, struct list_head *inode_list,
|
|||
* So, call recover_inode for the inode update.
|
||||
*/
|
||||
if (IS_INODE(&folio->page)) {
|
||||
err = recover_inode(entry->inode, &folio->page);
|
||||
err = recover_inode(entry->inode, folio);
|
||||
if (err) {
|
||||
f2fs_folio_put(folio, true);
|
||||
break;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user