summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/extent_io.h
diff options
context:
space:
mode:
authorQu Wenruo <wqu@suse.com>2024-01-29 20:16:10 +1030
committerDavid Sterba <dsterba@suse.com>2024-05-07 21:31:02 +0200
commit11e03f2f4b79eac2176d8ae5120bc9857e7fbb29 (patch)
tree9369a8bf1879651f8a1a56f2145e6c66455a0b78 /fs/btrfs/extent_io.h
parentae0d22a7fcb63863742c58be11b9e75ce2cbc9f5 (diff)
downloadlinux-11e03f2f4b79eac2176d8ae5120bc9857e7fbb29.tar.gz
linux-11e03f2f4b79eac2176d8ae5120bc9857e7fbb29.tar.bz2
linux-11e03f2f4b79eac2176d8ae5120bc9857e7fbb29.zip
btrfs: introduce btrfs_alloc_folio_array()
The new helper will do the same thing as btrfs_alloc_page_array(), but with folios. One extra difference is, there is no extra helper for bulk allocation, thus it may not be as efficient as the page version. Signed-off-by: Qu Wenruo <wqu@suse.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/extent_io.h')
-rw-r--r--fs/btrfs/extent_io.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/btrfs/extent_io.h b/fs/btrfs/extent_io.h
index 818431b37124..c81a9b546c9f 100644
--- a/fs/btrfs/extent_io.h
+++ b/fs/btrfs/extent_io.h
@@ -360,6 +360,8 @@ void btrfs_clear_buffer_dirty(struct btrfs_trans_handle *trans,
int btrfs_alloc_page_array(unsigned int nr_pages, struct page **page_array,
gfp_t extra_gfp);
+int btrfs_alloc_folio_array(unsigned int nr_folios, struct folio **folio_array,
+ gfp_t extra_gfp);
#ifdef CONFIG_BTRFS_FS_RUN_SANITY_TESTS
bool find_lock_delalloc_range(struct inode *inode,