[PATCH v3 51/66] mm/madvise: Use vma_next instead of vma linked list
From: Liam Howlett
Date: Mon Oct 04 2021 - 21:33:24 EST
From: "Liam R. Howlett" <Liam.Howlett@xxxxxxxxxx>
Signed-off-by: Liam R. Howlett <Liam.Howlett@xxxxxxxxxx>
---
mm/madvise.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/mm/madvise.c b/mm/madvise.c
index 0734db8d53a7..3a6fe7e1b080 100644
--- a/mm/madvise.c
+++ b/mm/madvise.c
@@ -1209,7 +1209,7 @@ int do_madvise(struct mm_struct *mm, unsigned long start, size_t len_in, int beh
if (start >= end)
goto out;
if (prev)
- vma = prev->vm_next;
+ vma = vma_next(mm, prev);
else /* madvise_remove dropped mmap_lock */
vma = find_vma(mm, start);
}
--
2.30.2