summaryrefslogtreecommitdiff
path: root/fs/btrfs/relocation.c
diff options
context:
space:
mode:
authorDavid Sterba <dsterba@suse.com>2024-02-16 15:49:27 +0100
committerDavid Sterba <dsterba@suse.com>2024-03-04 16:24:52 +0100
commit56430c14a627a70319b670aea53b117fd33e989f (patch)
treec0fa431c8b7560e78d83296001697466f030fba2 /fs/btrfs/relocation.c
parente6052347244bf9b2804465e7dc027af43020b5ff (diff)
btrfs: open code btrfs_backref_iter_free()
The helper is trivial and used only once, open code it. It's safe to remove the 'if', the pointer is validated in build_backref_tree(). Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/relocation.c')
-rw-r--r--fs/btrfs/relocation.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/btrfs/relocation.c b/fs/btrfs/relocation.c
index 2fca67f2b39b..f96f267fb4aa 100644
--- a/fs/btrfs/relocation.c
+++ b/fs/btrfs/relocation.c
@@ -523,7 +523,8 @@ static noinline_for_stack struct btrfs_backref_node *build_backref_tree(
if (handle_useless_nodes(rc, node))
node = NULL;
out:
- btrfs_backref_iter_free(iter);
+ btrfs_free_path(iter->path);
+ kfree(iter);
btrfs_free_path(path);
if (err) {
btrfs_backref_error_cleanup(cache, node);