diff mbox series

[f2fs-dev,094/153] f2fs: Use a folio in f2fs_truncate_xattr_node()

Message ID 20250331201256.1057782-95-willy@infradead.org (mailing list archive)
State New
Headers show
Series f2fs folio conversions for 6.16 | expand

Commit Message

Matthew Wilcox (Oracle) March 31, 2025, 8:11 p.m. UTC
Remove a call to compound_head().

Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
---
 fs/f2fs/node.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
diff mbox series

Patch

diff --git a/fs/f2fs/node.c b/fs/f2fs/node.c
index cc4c3ba98140..d1fa244c9fa7 100644
--- a/fs/f2fs/node.c
+++ b/fs/f2fs/node.c
@@ -1242,20 +1242,20 @@  int f2fs_truncate_xattr_node(struct inode *inode)
 	struct f2fs_sb_info *sbi = F2FS_I_SB(inode);
 	nid_t nid = F2FS_I(inode)->i_xattr_nid;
 	struct dnode_of_data dn;
-	struct page *npage;
+	struct folio *nfolio;
 	int err;
 
 	if (!nid)
 		return 0;
 
-	npage = f2fs_get_xnode_page(sbi, nid);
-	if (IS_ERR(npage))
-		return PTR_ERR(npage);
+	nfolio = f2fs_get_xnode_folio(sbi, nid);
+	if (IS_ERR(nfolio))
+		return PTR_ERR(nfolio);
 
-	set_new_dnode(&dn, inode, NULL, npage, nid);
+	set_new_dnode(&dn, inode, NULL, &nfolio->page, nid);
 	err = truncate_node(&dn);
 	if (err) {
-		f2fs_put_page(npage, 1);
+		f2fs_folio_put(nfolio, true);
 		return err;
 	}