]> git.karo-electronics.de Git - karo-tx-linux.git/commit
Btrfs: return gracefully from balance if fs tree is corrupted
authorLiu Bo <bo.li.liu@oracle.com>
Wed, 14 Sep 2016 15:51:46 +0000 (08:51 -0700)
committerDavid Sterba <dsterba@suse.com>
Mon, 26 Sep 2016 15:59:49 +0000 (17:59 +0200)
commit3561b9db70928f207be4570b48fc19898eeaef54
treeda7291956ca31e0717a99d2d8471fe42bb19065f
parent9c8e63db1de98c5cc3c6fb32d11b5cf55f228601
Btrfs: return gracefully from balance if fs tree is corrupted

When relocating tree blocks, we firstly get block information from
back references in the extent tree, we then search fs tree to try to
find all parents of a block.

However, if fs tree is corrupted, eg. if there're some missing
items, we could come across these WARN_ONs and BUG_ONs.

This makes us print some error messages and return gracefully
from balance.

Signed-off-by: Liu Bo <bo.li.liu@oracle.com>
Reviewed-by: Josef Bacik <jbacik@fb.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/relocation.c