]> git.baikalelectronics.ru Git - kernel.git/commit
Btrfs: cleanup transaction on abort
authorJosef Bacik <jbacik@fusionio.com>
Fri, 27 Sep 2013 20:32:39 +0000 (16:32 -0400)
committerChris Mason <chris.mason@fusionio.com>
Tue, 12 Nov 2013 02:53:42 +0000 (21:53 -0500)
commit4ac7071361ff5774d576ba6cdc3c3d11ce536334
treedebfa36ad00bef15ca1d052e98a315eda665c2ee
parenta82822af7fcf308f81cdbf2bcd8b89401e53c0fc
Btrfs: cleanup transaction on abort

If we abort not during a transaction commit we won't clean up anything until we
unmount.  Unfortunately if we abort in the middle of writing out an ordered
extent we won't clean it up and if somebody is waiting on that ordered extent
they will wait forever.  To fix this just make the transaction kthread call the
cleanup transaction stuff if it notices theres an error, and make
btrfs_end_transaction wake up the transaction kthread if there is an error.
Thanks,

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