From ee4b1fc24f30cff25257b2a77b6f44aad1db6e19 Mon Sep 17 00:00:00 2001 From: "Liam R. Howlett" Date: Wed, 20 Apr 2022 09:37:50 -0400 Subject: [PATCH] mm: Fix commit "mm: start tracking VMAs with maple tree" Hold the lock for the destruction of the maple tree to avoid lockdep issues - and potentially process_mrelease. Signed-off-by: Liam R. Howlett --- mm/mmap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/mmap.c b/mm/mmap.c index f172f3aba90f..dbfd3576b6d0 100644 --- a/mm/mmap.c +++ b/mm/mmap.c @@ -3163,9 +3163,9 @@ void exit_mmap(struct mm_struct *mm) BUG_ON(count != mm->map_count); - mmap_write_unlock(mm); trace_exit_mmap(mm); __mt_destroy(&mm->mm_mt); + mmap_write_unlock(mm); vm_unacct_memory(nr_accounted); } -- 2.34.1