aboutsummaryrefslogtreecommitdiffstats
path: root/fs/btrfs/extent-tree.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/btrfs/extent-tree.c')
-rw-r--r--fs/btrfs/extent-tree.c23
1 files changed, 23 insertions, 0 deletions
diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c
index a561060f5ffb..f619c3cb13b7 100644
--- a/fs/btrfs/extent-tree.c
+++ b/fs/btrfs/extent-tree.c
@@ -8778,6 +8778,29 @@ out:
8778 return ret; 8778 return ret;
8779} 8779}
8780 8780
8781int btrfs_init_space_info(struct btrfs_fs_info *fs_info)
8782{
8783 struct btrfs_space_info *space_info;
8784 int ret;
8785
8786 ret = update_space_info(fs_info, BTRFS_BLOCK_GROUP_SYSTEM, 0, 0,
8787 &space_info);
8788 if (ret)
8789 return ret;
8790
8791 ret = update_space_info(fs_info, BTRFS_BLOCK_GROUP_METADATA, 0, 0,
8792 &space_info);
8793 if (ret)
8794 return ret;
8795
8796 ret = update_space_info(fs_info, BTRFS_BLOCK_GROUP_DATA, 0, 0,
8797 &space_info);
8798 if (ret)
8799 return ret;
8800
8801 return ret;
8802}
8803
8781int btrfs_error_unpin_extent_range(struct btrfs_root *root, u64 start, u64 end) 8804int btrfs_error_unpin_extent_range(struct btrfs_root *root, u64 start, u64 end)
8782{ 8805{
8783 return unpin_extent_range(root, start, end); 8806 return unpin_extent_range(root, start, end);