aboutsummaryrefslogtreecommitdiff
path: root/include/trace
diff options
context:
space:
mode:
authorGravatar Josef Bacik <josef@toxicpanda.com> 2024-04-12 22:57:13 -0400
committerGravatar David Sterba <dsterba@suse.com> 2024-05-07 21:31:05 +0200
commitcf4f04325b2b27efa5697ba0ea4c1abdee0035b4 (patch)
treeca74b2f1022f2000511fb7411ee93b5319bdb050 /include/trace
parentbtrfs: rename ->len to ->num_bytes in btrfs_ref (diff)
downloadlinux-cf4f04325b2b27efa5697ba0ea4c1abdee0035b4.tar.gz
linux-cf4f04325b2b27efa5697ba0ea4c1abdee0035b4.tar.bz2
linux-cf4f04325b2b27efa5697ba0ea4c1abdee0035b4.zip
btrfs: move ->parent and ->ref_root into btrfs_delayed_ref_node
These two members are shared by both the tree refs and data refs, so move them into btrfs_delayed_ref_node proper. This allows us to greatly simplify the comparison code, as the shared refs always only sort on parent, and the non shared refs always sort first on ref_root, and then only data refs sort on their specific fields. Reviewed-by: Filipe Manana <fdmanana@suse.com> Signed-off-by: Josef Bacik <josef@toxicpanda.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'include/trace')
-rw-r--r--include/trace/events/btrfs.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/trace/events/btrfs.h b/include/trace/events/btrfs.h
index dae29f6d6b4c..e6cee75c384c 100644
--- a/include/trace/events/btrfs.h
+++ b/include/trace/events/btrfs.h
@@ -887,8 +887,8 @@ DECLARE_EVENT_CLASS(btrfs_delayed_tree_ref,
__entry->bytenr = ref->bytenr;
__entry->num_bytes = ref->num_bytes;
__entry->action = ref->action;
- __entry->parent = ref->tree_ref.parent;
- __entry->ref_root = ref->tree_ref.root;
+ __entry->parent = ref->parent;
+ __entry->ref_root = ref->ref_root;
__entry->level = ref->tree_ref.level;
__entry->type = ref->type;
__entry->seq = ref->seq;
@@ -945,8 +945,8 @@ DECLARE_EVENT_CLASS(btrfs_delayed_data_ref,
__entry->bytenr = ref->bytenr;
__entry->num_bytes = ref->num_bytes;
__entry->action = ref->action;
- __entry->parent = ref->data_ref.parent;
- __entry->ref_root = ref->data_ref.root;
+ __entry->parent = ref->parent;
+ __entry->ref_root = ref->ref_root;
__entry->owner = ref->data_ref.objectid;
__entry->offset = ref->data_ref.offset;
__entry->type = ref->type;