]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: change error handling for btrfs_delete_*_in_log
authorJosef Bacik <josef@toxicpanda.com>
Tue, 5 Oct 2021 20:35:24 +0000 (16:35 -0400)
committerDavid Sterba <dsterba@suse.com>
Tue, 26 Oct 2021 17:08:05 +0000 (19:08 +0200)
commit8f95f34556eb7b529dddd063c492efa144f30ec1
treec81496194c5babfe11b55a972ba5b2493e8ef9f6
parent4c4f8c073dfe4b2da10f6dc4e74c2e72cead05b3
btrfs: change error handling for btrfs_delete_*_in_log

Currently we will abort the transaction if we get a random error (like
-EIO) while trying to remove the directory entries from the root log
during rename.

However since these are simply log tree related errors, we can mark the
trans as needing a full commit.  Then if the error was truly
catastrophic we'll hit it during the normal commit and abort as
appropriate.

Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: Filipe Manana <fdmanana@suse.com>
Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/inode.c
fs/btrfs/tree-log.c
fs/btrfs/tree-log.h