summary refs log tree commit diff
path: root/block/bfq-wf2q.c
diff options
context:
space:
mode:
authorLiam R. Howlett <Liam.Howlett@oracle.com>2023-03-07 13:02:47 -0500
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2023-03-30 12:49:26 +0200
commit94f6b92bad23226a79f4b210e3740582c9d8947a (patch)
tree435bac1cf65681e500d5433c8ce26dec875e83f4 /block/bfq-wf2q.c
parent450317033f04e6dff5cf9b675a9797ee602e25e3 (diff)
downloadlinux-94f6b92bad23226a79f4b210e3740582c9d8947a.tar.gz
test_maple_tree: add more testing for mas_empty_area()
commit 4bd6dded6318dc8e2514d74868c1f8fb38b61a60 upstream.

Test robust filling of an entire area of the tree, then test one beyond.
This is to test the walking back up the tree at the end of nodes and error
condition.  Test inspired by the reproducer code provided by Snild Dolkow.

The last test in the function tests for the case of a corrupted maple
state caused by the incorrect limits set during mas_skip_node().  There
needs to be a gap in the second last child and last child, but the search
must rule out the second last child's gap.  This would avoid correcting
the maple state to the correct max limit and return an error.

Link: https://lkml.kernel.org/r/20230307180247.2220303-3-Liam.Howlett@oracle.com
Cc: Snild Dolkow <snild@sony.com>
Link: https://lore.kernel.org/linux-mm/cb8dc31a-fef2-1d09-f133-e9f7b9f9e77a@sony.com/
Fixes: e15e06a83923 ("lib/test_maple_tree: add testing for maple tree")
Signed-off-by: Liam R. Howlett <Liam.Howlett@oracle.com>
Cc: Peng Zhang <zhangpeng.00@bytedance.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'block/bfq-wf2q.c')
0 files changed, 0 insertions, 0 deletions