Skip to contentSkip to conversation

fixup! mm: fix a crash due to vma_end_read() that should have been removed

PATCH New Suren Baghdasaryan 1 participant 1 message Feb 20, 2025

Subsystems (2)
lore
Share & tools
lore

Suren Baghdasaryan

author reviewer
#0 lore raw

PATCH 1/1 fixup! mm: fix a crash due to vma_end_read() that should have been removed

Handling a vma lock failure due to vma being detached from under us got changed but vma_end_read() in that path was left untouched while it should have been removed. Remove it.

Fixes 758f7664c3d1 ("mm: replace vm_lock and detached flag with a reference count")
---
 mm/memory.c | 1 -
 1 file changed, 1 deletion(-)
mm/memory.c +0 -1
index cacf6d53bdf3..567b45e5d149 100644
@@ -6496,7 +6496,6 @@ struct vm_area_struct *lock_vma_under_rcu(struct mm_struct *mm,
 	if (IS_ERR_OR_NULL(vma)) {
 		/* Check if the VMA got isolated after we found it */
 		if (PTR_ERR(vma) == -EAGAIN) {
-			vma_end_read(vma);
 			count_vm_vma_lock_event(VMA_LOCK_MISS);
 			/* The area was replaced with another one */
 			goto retry;

base-commit: f7ed46277aaa8f848f18959ff68469f5186ba87c

Signature · 1 line
2.48.1.601.g30ceb7b040-goog