hc
2024-02-20 102a0743326a03cd1a1202ceda21e175b7d3575c
kernel/tools/testing/radix-tree/test.h
....@@ -11,13 +11,11 @@
1111 };
1212
1313 struct item *item_create(unsigned long index, unsigned int order);
14
-int __item_insert(struct radix_tree_root *root, struct item *item);
1514 int item_insert(struct radix_tree_root *root, unsigned long index);
1615 void item_sanity(struct item *item, unsigned long index);
17
-int item_insert_order(struct radix_tree_root *root, unsigned long index,
18
- unsigned order);
16
+void item_free(struct item *item, unsigned long index);
1917 int item_delete(struct radix_tree_root *root, unsigned long index);
20
-int item_delete_rcu(struct radix_tree_root *root, unsigned long index);
18
+int item_delete_rcu(struct xarray *xa, unsigned long index);
2119 struct item *item_lookup(struct radix_tree_root *root, unsigned long index);
2220
2321 void item_check_present(struct radix_tree_root *root, unsigned long index);
....@@ -29,14 +27,14 @@
2927 unsigned long nr, int chunk);
3028 void item_kill_tree(struct radix_tree_root *root);
3129
32
-int tag_tagged_items(struct radix_tree_root *, pthread_mutex_t *,
33
- unsigned long start, unsigned long end, unsigned batch,
34
- unsigned iftag, unsigned thentag);
35
-unsigned long find_item(struct radix_tree_root *, void *item);
30
+int tag_tagged_items(struct xarray *, unsigned long start, unsigned long end,
31
+ unsigned batch, xa_mark_t iftag, xa_mark_t thentag);
3632
33
+void xarray_tests(void);
3734 void tag_check(void);
3835 void multiorder_checks(void);
3936 void iteration_test(unsigned order, unsigned duration);
37
+void iteration_test2(unsigned duration);
4038 void benchmark(void);
4139 void idr_checks(void);
4240 void ida_tests(void);
....@@ -58,8 +56,4 @@
5856 unsigned long node_maxindex(struct radix_tree_node *);
5957 unsigned long shift_maxindex(unsigned int shift);
6058 int radix_tree_cpu_dead(unsigned int cpu);
61
-struct radix_tree_preload {
62
- unsigned nr;
63
- struct radix_tree_node *nodes;
64
-};
6559 extern struct radix_tree_preload radix_tree_preloads;