diff options
author | Josef Bacik <josef@toxicpanda.com> | 2024-04-13 05:57:13 +0300 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2024-05-07 22:31:05 +0300 |
commit | cf4f04325b2b27efa5697ba0ea4c1abdee0035b4 (patch) | |
tree | ca74b2f1022f2000511fb7411ee93b5319bdb050 /include/trace | |
parent | 12390e42b69d7e439cc2a266b6c7b4e1116de7c9 (diff) | |
download | linux-cf4f04325b2b27efa5697ba0ea4c1abdee0035b4.tar.xz |
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.h | 8 |
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; |