Btrfs: deal with enomem in the rewind path
authorJosef Bacik <jbacik@fusionio.com>
Wed, 7 Aug 2013 18:54:37 +0000 (14:54 -0400)
committerChris Mason <chris.mason@fusionio.com>
Sun, 1 Sep 2013 12:04:49 +0000 (08:04 -0400)
commitdb7f3436c1c186f8271018751fcb338cf3706e8d
tree100757837210358af57b870c5e54d1731692940b
parentebdad913aa9c86a63d3be28b4610e143204c6f3c
Btrfs: deal with enomem in the rewind path

We can get ENOMEM trying to allocate dummy bufs for the rewind operation of the
tree mod log.  Instead of BUG_ON()'ing in this case pass up ENOMEM.  I looked
back through the callers and I'm pretty sure I got everybody who did BUG_ON(ret)
in this path.  Thanks,

Signed-off-by: Josef Bacik <jbacik@fusionio.com>
Signed-off-by: Chris Mason <chris.mason@fusionio.com>
fs/btrfs/ctree.c
fs/btrfs/extent_io.c