From: Chris Mason Date: Fri, 29 Oct 2010 13:27:49 +0000 (-0400) Subject: Merge branch 'bug-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/josef/btrfs... X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=6b5b817f103450444f3f658a498f435d92a197e5;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git Merge branch 'bug-fixes' of git://git./linux/kernel/git/josef/btrfs-work Conflicts: fs/btrfs/extent-tree.c Signed-off-by: Chris Mason --- 6b5b817f103450444f3f658a498f435d92a197e5 diff --cc fs/btrfs/extent-tree.c index d2a7ff53e99a,33785333f293..372fd224a11d --- a/fs/btrfs/extent-tree.c +++ b/fs/btrfs/extent-tree.c @@@ -8389,10 -8122,9 +8423,11 @@@ int btrfs_remove_block_group(struct btr struct btrfs_path *path; struct btrfs_block_group_cache *block_group; struct btrfs_free_cluster *cluster; + struct btrfs_root *tree_root = root->fs_info->tree_root; struct btrfs_key key; + struct inode *inode; int ret; + int factor; root = root->fs_info->extent_root; @@@ -8473,10 -8179,9 +8516,11 @@@ spin_lock(&block_group->space_info->lock); block_group->space_info->total_bytes -= block_group->key.offset; block_group->space_info->bytes_readonly -= block_group->key.offset; + block_group->space_info->disk_total -= block_group->key.offset * factor; spin_unlock(&block_group->space_info->lock); + memcpy(&key, &block_group->key, sizeof(key)); + btrfs_clear_space_info_full(root->fs_info); btrfs_put_block_group(block_group);