summaryrefslogtreecommitdiff
path: root/cmds-inspect-tree-stats.c
diff options
context:
space:
mode:
authorQu Wenruo <quwenruo@cn.fujitsu.com>2017-05-18 10:51:08 +0800
committerDavid Sterba <dsterba@suse.com>2017-07-03 13:35:11 +0200
commit8690c887d1dcad384d44ca21bf950a4ec2fbffdb (patch)
treebf736b51824e4e834c4d0e8ea79169bf40849d04 /cmds-inspect-tree-stats.c
parent060c7b3a1a40d2e9cacbdb37a02791bacae32491 (diff)
btrfs-progs: Refactor read_tree_block to get rid of btrfs_root
The only reasom read_tree_block() needs a btrfs_root parameter is to get its node/sector size. And long ago, I have already introduced a compactible interface, read_tree_block_fs_info() to pass btrfs_fs_info instead of btrfs_root. Since we have cleaned up all root->sector/node/stripesize users, we should be OK to refactor read_tree_block() function. Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com>
Diffstat (limited to 'cmds-inspect-tree-stats.c')
-rw-r--r--cmds-inspect-tree-stats.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/cmds-inspect-tree-stats.c b/cmds-inspect-tree-stats.c
index ecb33ce..05f4f61 100644
--- a/cmds-inspect-tree-stats.c
+++ b/cmds-inspect-tree-stats.c
@@ -153,7 +153,7 @@ static int walk_nodes(struct btrfs_root *root, struct btrfs_path *path,
path->slots[level] = i;
if ((level - 1) > 0 || find_inline) {
- tmp = read_tree_block(root, cur_blocknr,
+ tmp = read_tree_block(root->fs_info, cur_blocknr,
nodesize,
btrfs_node_ptr_generation(b, i));
if (!extent_buffer_uptodate(tmp)) {