]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
maple_tree: Move xa_get_alloc_size
authorMatthew Wilcox (Oracle) <willy@infradead.org>
Thu, 27 Feb 2020 15:16:09 +0000 (10:16 -0500)
committerLiam R. Howlett <Liam.Howlett@Oracle.com>
Tue, 5 Jan 2021 17:28:23 +0000 (12:28 -0500)
... into ma_xa_benchmark.

Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
lib/xarray.c
tools/testing/radix-tree/ma_xa_benchmark.c

index 3b2c53507f438970fda8f6862f7d2be560174d47..5fa51614802ada34af73623a7cab609e236af856 100644 (file)
@@ -2294,10 +2294,4 @@ void xa_dump(const struct xarray *xa)
                shift = xa_to_node(entry)->shift + XA_CHUNK_SHIFT;
        xa_dump_entry(entry, 0, shift);
 }
-
-extern unsigned long kmem_cache_get_alloc(struct kmem_cache *);
-unsigned long xa_get_alloc_size(void)
-{
-       return kmem_cache_get_alloc(radix_tree_node_cachep);
-}
 #endif
index f6218898cebbb59757d156f843a8e1f19c23037a..1f7a0c743916b1b35564f18f35c82c01ecd147af 100644 (file)
 #include <linux/maple_tree.h>
 #include <linux/xarray.h>
 
+extern unsigned long kmem_cache_get_alloc(struct kmem_cache *);
+extern struct kmem_cache *radix_tree_node_cachep;
+unsigned long xa_get_alloc_size(void)
+{
+       return kmem_cache_get_alloc(radix_tree_node_cachep);
+}
 
-
-extern unsigned long xa_get_alloc_size(void);
 extern unsigned long mt_get_alloc_size(void);
 
 int __weak main(void)