aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/radix-tree/xarray.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2018-10-21xarray: Add XArray load operationMatthew Wilcox1-0/+28
The xa_load function brings with it a lot of infrastructure; xa_empty(), xa_is_err(), and large chunks of the XArray advanced API that are used to implement xa_load. As the test-suite demonstrates, it is possible to use the XArray functions on a radix tree. The radix tree functions depend on the GFP flags being stored in the root of the tree, so it's not possible to use the radix tree functions on an XArray. Signed-off-by: Matthew Wilcox <willy@infradead.org>
2018-10-21xarray: Add definition of struct xarrayMatthew Wilcox1-0/+7
This is a direct replacement for struct radix_tree_root. Some of the struct members have changed name; convert those, and use a #define so that radix_tree users continue to work without change. Signed-off-by: Matthew Wilcox <willy@infradead.org> Reviewed-by: Josef Bacik <jbacik@fb.com>