summaryrefslogtreecommitdiff
path: root/fs/btrfs/disk-io.h
diff options
context:
space:
mode:
authorJosef Bacik <josef@toxicpanda.com>2021-11-05 23:45:48 +0300
committerDavid Sterba <dsterba@suse.com>2022-01-03 17:09:49 +0300
commitfc28b25e1f428651133326300d9572b42aae6d8f (patch)
tree6fa19060d267497123fdcdadafbd9ba62a6c6dc1 /fs/btrfs/disk-io.h
parent056c83111648a92233f0445bb4a6c1aeafe6be98 (diff)
downloadlinux-fc28b25e1f428651133326300d9572b42aae6d8f.tar.xz
btrfs: stop accessing ->csum_root directly
We are going to have multiple csum roots in the future, so convert all users of ->csum_root to btrfs_csum_root() and rename ->csum_root to ->_csum_root so we can easily find remaining users in the future. Signed-off-by: Josef Bacik <josef@toxicpanda.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/disk-io.h')
-rw-r--r--fs/btrfs/disk-io.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/btrfs/disk-io.h b/fs/btrfs/disk-io.h
index e2824c6ada72..a4d1788acd24 100644
--- a/fs/btrfs/disk-io.h
+++ b/fs/btrfs/disk-io.h
@@ -109,6 +109,12 @@ static inline struct btrfs_root *btrfs_extent_root(struct btrfs_fs_info *fs_info
return fs_info->_extent_root;
}
+static inline struct btrfs_root *btrfs_csum_root(struct btrfs_fs_info *fs_info,
+ u64 bytenr)
+{
+ return fs_info->_csum_root;
+}
+
static inline struct btrfs_root *btrfs_block_group_root(struct btrfs_fs_info *fs_info)
{
return btrfs_extent_root(fs_info, 0);