在 2023/7/3 02:20, Geert Uytterhoeven 写道:
Hi Liam,
On Thu, May 18, 2023 at 9:37 PM Liam R. Howlett Liam.Howlett@oracle.com wrote:
Now that the functions have changed the limits, update the testing of the maple tree to test these new settings.
Signed-off-by: Liam R. Howlett Liam.Howlett@oracle.com
Thanks for your patch, which is now commit eb2e817f38cafbf7 ("maple_tree: update testing code for mas_{next,prev,walk}") in
--- a/lib/test_maple_tree.c +++ b/lib/test_maple_tree.c @@ -2011,7 +2011,7 @@ static noinline void __init next_prev_test(struct maple_tree *mt)
val = mas_next(&mas, ULONG_MAX); MT_BUG_ON(mt, val != NULL);
MT_BUG_ON(mt, mas.index != ULONG_MAX);
MT_BUG_ON(mt, mas.index != 0x7d6);
On m68k (ARAnyM):
TEST STARTING BUG at next_prev_test:2014 (1) Pass: 3749128 Run:3749129
And after that it seems to hang[*].
After adding a debug print (thus shifting all line numbers by +1):
next_prev_test:mas.index = 0x138e BUG at next_prev_test:2015 (1)
0x138e = 5006, while the expected value is 0x7d6 = 2006.
I took a look. The return value 5006 is correct while the expected value is wrong. This is a problem with the test, it is not compatible with 32-bit systems.
I guess converting this test to the KUnit framework would make it a bit easier to investigate failures...
[*] Left the debug one running, and I got a few more:
BUG at check_empty_area_window:2656 (1) Pass: 3754275 Run:3754277 BUG at check_empty_area_window:2657 (1) Pass: 3754275 Run:3754278 BUG at check_empty_area_window:2658 (1) Pass: 3754275 Run:3754279 BUG at check_empty_area_window:2662 (1) Pass: 3754275 Run:3754280 BUG at check_empty_area_window:2663 (1) Pass: 3754275 Run:3754281 maple_tree: 3804518 of 3804524 tests passed
So the full test took more than 20 minutes...
MT_BUG_ON(mt, mas.last != ULONG_MAX); val = mas_prev(&mas, 0);
Gr{oetje,eeting}s,
Geert
-- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds