f2fs: Use a folio in f2fs_encrypted_get_link()
authorMatthew Wilcox (Oracle) <willy@infradead.org>
Tue, 8 Jul 2025 17:03:51 +0000 (18:03 +0100)
committerJaegeuk Kim <jaegeuk@kernel.org>
Tue, 22 Jul 2025 15:57:54 +0000 (15:57 +0000)
Use a folio instead of a page when dealing with the page cache.  Removes
a hidden call to compound_head().

Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/namei.c

index 07e333ee21b7262392fe30753d63c75612358a77..b882771e469971dcf4e7a42416f9fbb8a5d9bf39 100644 (file)
@@ -1298,19 +1298,19 @@ static const char *f2fs_encrypted_get_link(struct dentry *dentry,
                                           struct inode *inode,
                                           struct delayed_call *done)
 {
-       struct page *page;
+       struct folio *folio;
        const char *target;
 
        if (!dentry)
                return ERR_PTR(-ECHILD);
 
-       page = read_mapping_page(inode->i_mapping, 0, NULL);
-       if (IS_ERR(page))
-               return ERR_CAST(page);
+       folio = read_mapping_folio(inode->i_mapping, 0, NULL);
+       if (IS_ERR(folio))
+               return ERR_CAST(folio);
 
-       target = fscrypt_get_symlink(inode, page_address(page),
+       target = fscrypt_get_symlink(inode, folio_address(folio),
                                     inode->i_sb->s_blocksize, done);
-       put_page(page);
+       folio_put(folio);
        return target;
 }