mm: add vma_iter_{next,prev}_range() to vma iterator
authorLiam R. Howlett <Liam.Howlett@oracle.com>
Thu, 18 May 2023 14:55:43 +0000 (10:55 -0400)
committerAndrew Morton <akpm@linux-foundation.org>
Fri, 9 Jun 2023 23:25:35 +0000 (16:25 -0700)
commitbb5dbd2272b8d7b3a34d234bb916819afbf802d1
treecc4bf310a28fa9c3b8ac878bc9bc6f4f203855a6
parenteb2e817f38cafbf776ffec9b273aaada6ffc274d
mm: add vma_iter_{next,prev}_range() to vma iterator

Add functionality to the VMA iterator to advance and retreat one offset
within the maple tree, regardless of the value contained.  This can lead
to less re-walking to find an area of interest, especially when there is
nothing in that offset.

Link: https://lkml.kernel.org/r/20230518145544.1722059-35-Liam.Howlett@oracle.com
Signed-off-by: Liam R. Howlett <Liam.Howlett@oracle.com>
Cc: David Binderman <dcb314@hotmail.com>
Cc: Peng Zhang <zhangpeng.00@bytedance.com>
Cc: Sergey Senozhatsky <senozhatsky@chromium.org>
Cc: Vernon Yang <vernon2gm@gmail.com>
Cc: Wei Yang <richard.weiyang@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
include/linux/mm.h