]> www.infradead.org Git - users/willy/linux.git/commit
mm/mmap: Use advanced maple tree API for mmap_region()
authorLiam R. Howlett <Liam.Howlett@Oracle.com>
Tue, 10 Nov 2020 18:37:40 +0000 (13:37 -0500)
committerMatthew Wilcox (Oracle) <willy@infradead.org>
Wed, 20 Oct 2021 20:00:32 +0000 (16:00 -0400)
commitbcfa0a44a4a9e9efde71ba29a742e34b7075cf05
treebbde93fed52804c43916dd90d863d0140d5fcf1f
parente38b1ded938aeb116f503cf5b4c41449f53a738c
mm/mmap: Use advanced maple tree API for mmap_region()

Changing mmap_region() to use the maple tree state and the advanced
maple tree interface allows for a lot less tree walking.

This change removes the last caller of munmap_vma_range(), so drop this
unused function.

Add vma_expand() to expand a VMA if possible by doing the necessary
hugepage check, uprobe_munmap of files, dcache flush, modifications then
undoing the detaches, etc.

Add vma_mas_link() helper to add a VMA to the linked list and maple tree
until the linked list is removed.

Signed-off-by: Liam R. Howlett <Liam.Howlett@Oracle.com>
mm/mmap.c