]> www.infradead.org Git - users/jedix/linux-maple.git/commit
damon: Convert __damon_va_three_regions to use the VMA iterator
authorMatthew Wilcox (Oracle) <willy@infradead.org>
Thu, 28 Oct 2021 18:39:28 +0000 (14:39 -0400)
committerLiam R. Howlett <Liam.Howlett@oracle.com>
Mon, 14 Mar 2022 18:49:44 +0000 (14:49 -0400)
commite0804efa51ae4d37b6c3a814f2d37c389c108ef9
tree84c2a915cbd05dbf4959e510b8419b799491dede
parent60073e0ed220f2392736f6f340807748da2bc8c3
damon: Convert __damon_va_three_regions to use the VMA iterator

This rather specialised walk can use the VMA iterator.  If this proves
to be too slow, we can write a custom routine to find the two largest
gaps, but it will be somewhat complicated, so let's see if we need it
first.

Update the kunit test case to use the maple tree.  This also fixes an
issue with the kunit testcase not adding the last VMA to the list.

Fixes: 17ccae8bb5c9 (mm/damon: add kunit tests)
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Signed-off-by: Liam R. Howlett <Liam.Howlett@Oracle.com>
mm/damon/vaddr-test.h
mm/damon/vaddr.c