mbox series

[v2,0/2] mm/mremap: Remove extra vma tree walk

Message ID 20241018174114.2871880-1-Liam.Howlett@oracle.com (mailing list archive)
Headers show
Series mm/mremap: Remove extra vma tree walk | expand

Message

Liam R. Howlett Oct. 18, 2024, 5:41 p.m. UTC
An extra vma tree walk was discovered in some mremap call paths during
the discussion on mseal() changes.  This patch set removes the extra vma
tree walk and further cleans up mremap_to().

v1: https://lore.kernel.org/all/20241016201719.2449143-1-Liam.Howlett@oracle.com/

Changes since v1:
 Change mremap_vma_check() to resize_is_valid() - Thanks Jeff & Andrew
 Fixed missing return check - Thanks Andrew
 Added comments to both functions that are touched - Thanks Andrew

Liam R. Howlett (2):
  mm/mremap: Clean up vma_to_resize()
  mm/mremap: Remove goto from mremap_to()

 mm/mremap.c | 93 +++++++++++++++++++++++++++++++----------------------
 1 file changed, 55 insertions(+), 38 deletions(-)