btrfs: handle extent reference errors in do_relocation
authorJosef Bacik <josef@toxicpanda.com>
Fri, 12 Mar 2021 20:25:25 +0000 (15:25 -0500)
committerDavid Sterba <dsterba@suse.com>
Mon, 19 Apr 2021 15:25:21 +0000 (17:25 +0200)
commiteb6b7fb4b544ae0ab19a85b55ca548d838dc4beb
tree969bde38f44555761876f08c2ecbdcaebe71f4e9
parent253e258c34262c50ce2622b38d2769911a9cddfd
btrfs: handle extent reference errors in do_relocation

We can already deal with errors appropriately from do_relocation, simply
handle any errors that come from changing the refs at this point
cleanly.  We have to abort the transaction if we fail here as we've
modified metadata at this point.

Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/relocation.c