* [PATCH 4/4] Btrfs: remove useless 'fail_unlock' label from btrfs_csum_file_blocks()
@ 2020-05-18 11:15 fdmanana
0 siblings, 0 replies; only message in thread
From: fdmanana @ 2020-05-18 11:15 UTC (permalink / raw)
To: linux-btrfs
From: Filipe Manana <fdmanana@suse.com>
The label 'fail_unlock' is pointless, all it does is to jump to the label
'out', so just remove it.
Signed-off-by: Filipe Manana <fdmanana@suse.com>
---
fs/btrfs/file-item.c | 11 ++++-------
1 file changed, 4 insertions(+), 7 deletions(-)
diff --git a/fs/btrfs/file-item.c b/fs/btrfs/file-item.c
index 4f563469c97a..80a4651b72f5 100644
--- a/fs/btrfs/file-item.c
+++ b/fs/btrfs/file-item.c
@@ -869,7 +869,7 @@ int btrfs_csum_file_blocks(struct btrfs_trans_handle *trans,
}
ret = PTR_ERR(item);
if (ret != -EFBIG && ret != -ENOENT)
- goto fail_unlock;
+ goto out;
if (ret == -EFBIG) {
u32 item_size;
@@ -927,7 +927,7 @@ int btrfs_csum_file_blocks(struct btrfs_trans_handle *trans,
ret = btrfs_search_slot(trans, root, &file_key, path,
csum_size, 1);
if (ret < 0)
- goto fail_unlock;
+ goto out;
if (ret > 0) {
if (path->slots[0] == 0)
@@ -994,9 +994,9 @@ int btrfs_csum_file_blocks(struct btrfs_trans_handle *trans,
ins_size);
path->leave_spinning = 0;
if (ret < 0)
- goto fail_unlock;
+ goto out;
if (WARN_ON(ret != 0))
- goto fail_unlock;
+ goto out;
leaf = path->nodes[0];
csum:
item = btrfs_item_ptr(leaf, path->slots[0], struct btrfs_csum_item);
@@ -1026,9 +1026,6 @@ int btrfs_csum_file_blocks(struct btrfs_trans_handle *trans,
out:
btrfs_free_path(path);
return ret;
-
-fail_unlock:
- goto out;
}
void btrfs_extent_item_to_extent_map(struct btrfs_inode *inode,
--
2.11.0
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2020-05-18 11:15 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-05-18 11:15 [PATCH 4/4] Btrfs: remove useless 'fail_unlock' label from btrfs_csum_file_blocks() fdmanana
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).