Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
[platform/adaptation/renesas_rcar/renesas_kernel.git] / arch / mips / mm / fault.c
index 0fead53..85df1cd 100644 (file)
@@ -5,6 +5,7 @@
  *
  * Copyright (C) 1995 - 2000 by Ralf Baechle
  */
+#include <linux/context_tracking.h>
 #include <linux/signal.h>
 #include <linux/sched.h>
 #include <linux/interrupt.h>
@@ -32,8 +33,8 @@
  * and the problem, and then passes it off to one of the appropriate
  * routines.
  */
-asmlinkage void __kprobes do_page_fault(struct pt_regs *regs, unsigned long write,
-                             unsigned long address)
+static void __kprobes __do_page_fault(struct pt_regs *regs, unsigned long write,
+       unsigned long address)
 {
        struct vm_area_struct * vma = NULL;
        struct task_struct *tsk = current;
@@ -312,3 +313,13 @@ vmalloc_fault:
        }
 #endif
 }
+
+asmlinkage void __kprobes do_page_fault(struct pt_regs *regs,
+       unsigned long write, unsigned long address)
+{
+       enum ctx_state prev_state;
+
+       prev_state = exception_enter();
+       __do_page_fault(regs, write, address);
+       exception_exit(prev_state);
+}