summaryrefslogtreecommitdiff
path: root/fs/btrfs/tree-log.c
diff options
context:
space:
mode:
authorFilipe Manana <fdmanana@suse.com>2025-08-27 15:24:08 +0100
committerDavid Sterba <dsterba@suse.com>2025-09-23 08:49:18 +0200
commit7790a882ca6bfe24392080605e5ba19f138ac29d (patch)
tree7b2d5065adadf85acaaf61de03565ff802f9d380 /fs/btrfs/tree-log.c
parent2f5b8095ea47b142c56c09755a8b1e14145a2d30 (diff)
btrfs: pass walk_control structure to replay_xattr_deletes()
Instead of passing the transaction, subvolume root and log tree as arguments to replay_xattr_deletes(), pass the walk_control structure as we can grab all of those from the structure. This reduces the number of arguments passed and it's going to be needed by an incoming change that improves error reporting for log replay. Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/tree-log.c')
-rw-r--r--fs/btrfs/tree-log.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c
index 4d34aee0cafa..cd4c5ae3e0a3 100644
--- a/fs/btrfs/tree-log.c
+++ b/fs/btrfs/tree-log.c
@@ -2336,12 +2336,13 @@ out:
return ret;
}
-static int replay_xattr_deletes(struct btrfs_trans_handle *trans,
- struct btrfs_root *root,
- struct btrfs_root *log,
- struct btrfs_path *path,
- const u64 ino)
+static int replay_xattr_deletes(struct walk_control *wc,
+ struct btrfs_path *path,
+ const u64 ino)
{
+ struct btrfs_trans_handle *trans = wc->trans;
+ struct btrfs_root *root = wc->root;
+ struct btrfs_root *log = wc->log;
struct btrfs_key search_key;
struct btrfs_path *log_path;
int i;
@@ -2645,7 +2646,7 @@ static int replay_one_buffer(struct extent_buffer *eb,
wc->stage == LOG_WALK_REPLAY_INODES) {
u32 mode;
- ret = replay_xattr_deletes(trans, root, log, path, key.objectid);
+ ret = replay_xattr_deletes(wc, path, key.objectid);
if (ret)
break;
mode = btrfs_inode_mode(eb, inode_item);