]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - arch/arm64/mm/fault.c
arm64/mm: Drop mmap_sem before calling __do_kernel_fault()
[linux.git] / arch / arm64 / mm / fault.c
index 392386a693fed4f84bf570ab01a5c4870ab7f86d..2256a1a09f1b163f62c6a62abbea7288601f3ba7 100644 (file)
@@ -504,8 +504,10 @@ static int __kprobes do_page_fault(unsigned long addr, unsigned int esr,
                 */
                might_sleep();
 #ifdef CONFIG_DEBUG_VM
-               if (!user_mode(regs) && !search_exception_tables(regs->pc))
+               if (!user_mode(regs) && !search_exception_tables(regs->pc)) {
+                       up_read(&mm->mmap_sem);
                        goto no_context;
+               }
 #endif
        }