mm, kprobes: generalize and rename notify_page_fault() as kprobe_page_fault()
[linux-2.6-microblaze.git] / arch / sparc / mm / fault_64.c
index 83fda4d..2371fb6 100644 (file)
 
 int show_unhandled_signals = 1;
 
-static inline __kprobes int notify_page_fault(struct pt_regs *regs)
-{
-       int ret = 0;
-
-       /* kprobe_running() needs smp_processor_id() */
-       if (kprobes_built_in() && !user_mode(regs)) {
-               preempt_disable();
-               if (kprobe_running() && kprobe_fault_handler(regs, 0))
-                       ret = 1;
-               preempt_enable();
-       }
-       return ret;
-}
-
 static void __kprobes unhandled_fault(unsigned long address,
                                      struct task_struct *tsk,
                                      struct pt_regs *regs)
@@ -285,7 +271,7 @@ asmlinkage void __kprobes do_sparc64_fault(struct pt_regs *regs)
 
        fault_code = get_thread_fault_code();
 
-       if (notify_page_fault(regs))
+       if (kprobe_page_fault(regs, 0))
                goto exit_exception;
 
        si_code = SEGV_MAPERR;