mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
Btrfs: Fix BUG_ON for fs converted from extN
Tree blocks can live in data block groups in FS converted from extN. So it's easy to trigger the BUG_ON. Signed-off-by: Yan Zheng <[email protected]> Signed-off-by: Chris Mason <[email protected]>
This commit is contained in:
parent
046f264f6b
commit
3bf84a5a83
1 changed files with 2 additions and 1 deletions
|
|
@ -4360,7 +4360,8 @@ void btrfs_free_tree_block(struct btrfs_trans_handle *trans,
|
|||
|
||||
block_rsv = get_block_rsv(trans, root);
|
||||
cache = btrfs_lookup_block_group(root->fs_info, buf->start);
|
||||
BUG_ON(block_rsv->space_info != cache->space_info);
|
||||
if (block_rsv->space_info != cache->space_info)
|
||||
goto out;
|
||||
|
||||
if (btrfs_header_generation(buf) == trans->transid) {
|
||||
if (root->root_key.objectid != BTRFS_TREE_LOG_OBJECTID) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue