summaryrefslogtreecommitdiff
path: root/fs/btrfs/delalloc-space.c
diff options
context:
space:
mode:
authorNaohiro Aota <naohiro.aota@wdc.com>2025-04-23 05:43:41 +0300
committerDavid Sterba <dsterba@suse.com>2025-05-15 15:30:52 +0300
commit5d39fda880bed9acaaa0b31601008751e27aabc8 (patch)
tree0f5673bbe24f0f6f75374806bbbe697f80a700e9 /fs/btrfs/delalloc-space.c
parent66864101d1b76f7f3417274a954b160e81903a94 (diff)
downloadlinux-5d39fda880bed9acaaa0b31601008751e27aabc8.tar.xz
btrfs: pass btrfs_space_info to btrfs_reserve_data_bytes()
Pass struct btrfs_space_info to btrfs_reserve_data_bytes() to allow reserving the data from multiple data space_info candidates. This is a preparation for the following commits and there is no functional change. Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com> Signed-off-by: Naohiro Aota <naohiro.aota@wdc.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/delalloc-space.c')
-rw-r--r--fs/btrfs/delalloc-space.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/btrfs/delalloc-space.c b/fs/btrfs/delalloc-space.c
index 1479be2427cb..c7181779b013 100644
--- a/fs/btrfs/delalloc-space.c
+++ b/fs/btrfs/delalloc-space.c
@@ -123,7 +123,7 @@ int btrfs_alloc_data_chunk_ondemand(const struct btrfs_inode *inode, u64 bytes)
if (btrfs_is_free_space_inode(inode))
flush = BTRFS_RESERVE_FLUSH_FREE_SPACE_INODE;
- return btrfs_reserve_data_bytes(fs_info, bytes, flush);
+ return btrfs_reserve_data_bytes(fs_info->data_sinfo, bytes, flush);
}
int btrfs_check_data_free_space(struct btrfs_inode *inode,
@@ -144,7 +144,7 @@ int btrfs_check_data_free_space(struct btrfs_inode *inode,
else if (btrfs_is_free_space_inode(inode))
flush = BTRFS_RESERVE_FLUSH_FREE_SPACE_INODE;
- ret = btrfs_reserve_data_bytes(fs_info, len, flush);
+ ret = btrfs_reserve_data_bytes(fs_info->data_sinfo, len, flush);
if (ret < 0)
return ret;