diff options
author | Matthew Wilcox <mawilcox@microsoft.com> | 2017-01-17 01:10:21 +0300 |
---|---|---|
committer | Matthew Wilcox <mawilcox@microsoft.com> | 2017-02-14 05:44:05 +0300 |
commit | d58275bc96ae933b1b3888af80920dd6b020c505 (patch) | |
tree | e1acf252dc43eeb1d65e4f715b0a1d52b1b4af09 /include/linux/radix-tree.h | |
parent | 1293d5c5f54d5118fbb34fc94e01ba02fcd25fc1 (diff) | |
download | linux-d58275bc96ae933b1b3888af80920dd6b020c505.tar.xz |
radix-tree: Store a pointer to the root in each node
Instead of having this mysterious private_data in each radix_tree_node,
store a pointer to the root, which can be useful for debugging. This also
relieves the mm code from the duty of updating it.
Acked-by: Johannes Weiner <hannes@cmpxchg.org>
Signed-off-by: Matthew Wilcox <mawilcox@microsoft.com>
Diffstat (limited to 'include/linux/radix-tree.h')
-rw-r--r-- | include/linux/radix-tree.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/radix-tree.h b/include/linux/radix-tree.h index 2ba0c1f46c84..d250059bbfa4 100644 --- a/include/linux/radix-tree.h +++ b/include/linux/radix-tree.h @@ -96,7 +96,7 @@ struct radix_tree_node { unsigned char count; /* Total entry count */ unsigned char exceptional; /* Exceptional entry count */ struct radix_tree_node *parent; /* Used when ascending tree */ - void *private_data; /* For tree user */ + struct radix_tree_root *root; /* The tree we belong to */ union { struct list_head private_list; /* For tree user */ struct rcu_head rcu_head; /* Used when freeing node */ |