diff options
author | Matthew Wilcox <willy@infradead.org> | 2018-08-18 07:09:22 -0400 |
---|---|---|
committer | Matthew Wilcox <willy@infradead.org> | 2018-10-21 10:46:45 -0400 |
commit | 372266ba0267803564824b1c09f1bb7f3f3fc761 (patch) | |
tree | e0f2551f5b51b793afe4fe7edfcaf5da6fce974d /tools/testing/radix-tree/regression2.c | |
parent | adb9d9c4ccb1ff0bf1d376e65f36aa5573c75c1a (diff) | |
download | linux-stable-372266ba0267803564824b1c09f1bb7f3f3fc761.tar.gz linux-stable-372266ba0267803564824b1c09f1bb7f3f3fc761.tar.bz2 linux-stable-372266ba0267803564824b1c09f1bb7f3f3fc761.zip |
radix tree test suite: Convert tag_tagged_items to XArray
The tag_tagged_items() function is supposed to test the page-writeback
tagging code. Since that has been converted to the XArray, there's
not much point in testing the radix tree's tagging code. This requires
using the pthread mutex embedded in the xarray instead of an external
lock, so remove the pthread mutexes which protect xarrays/radix trees.
Also remove radix_tree_iter_tag_set() as this was the last user.
Signed-off-by: Matthew Wilcox <willy@infradead.org>
Diffstat (limited to 'tools/testing/radix-tree/regression2.c')
-rw-r--r-- | tools/testing/radix-tree/regression2.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/testing/radix-tree/regression2.c b/tools/testing/radix-tree/regression2.c index 424b91c77831..f2c7e640a919 100644 --- a/tools/testing/radix-tree/regression2.c +++ b/tools/testing/radix-tree/regression2.c @@ -53,9 +53,9 @@ #include "regression.h" #include "test.h" -#define PAGECACHE_TAG_DIRTY 0 -#define PAGECACHE_TAG_WRITEBACK 1 -#define PAGECACHE_TAG_TOWRITE 2 +#define PAGECACHE_TAG_DIRTY XA_MARK_0 +#define PAGECACHE_TAG_WRITEBACK XA_MARK_1 +#define PAGECACHE_TAG_TOWRITE XA_MARK_2 static RADIX_TREE(mt_tree, GFP_KERNEL); unsigned long page_count = 0; @@ -92,7 +92,7 @@ void regression2_test(void) /* 1. */ start = 0; end = max_slots - 2; - tag_tagged_items(&mt_tree, NULL, start, end, 1, + tag_tagged_items(&mt_tree, start, end, 1, PAGECACHE_TAG_DIRTY, PAGECACHE_TAG_TOWRITE); /* 2. */ |