diff options
author | David S. Miller <davem@davemloft.net> | 2009-12-10 18:02:19 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-12-10 18:02:19 -0800 |
commit | 135d082171766922c6a9e2c741a326e518268428 (patch) | |
tree | 26a96b4971e7d3e0a9d743516c6c8e506caca2aa /arch/sparc | |
parent | 936cf251787be41833afe2a1e44fbd5fb2adbdb6 (diff) | |
download | kernel_samsung_tuna-135d082171766922c6a9e2c741a326e518268428.zip kernel_samsung_tuna-135d082171766922c6a9e2c741a326e518268428.tar.gz kernel_samsung_tuna-135d082171766922c6a9e2c741a326e518268428.tar.bz2 |
sparc64: Use kprobes_built_in() to avoid ifdefs in fault_64.c
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc')
-rw-r--r-- | arch/sparc/mm/fault_64.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/arch/sparc/mm/fault_64.c b/arch/sparc/mm/fault_64.c index 43b0da9..0aa50b2 100644 --- a/arch/sparc/mm/fault_64.c +++ b/arch/sparc/mm/fault_64.c @@ -31,13 +31,12 @@ #include <asm/sections.h> #include <asm/mmu_context.h> -#ifdef CONFIG_KPROBES static inline int notify_page_fault(struct pt_regs *regs) { int ret = 0; /* kprobe_running() needs smp_processor_id() */ - if (!user_mode(regs)) { + if (kprobes_built_in() && !user_mode(regs)) { preempt_disable(); if (kprobe_running() && kprobe_fault_handler(regs, 0)) ret = 1; @@ -45,12 +44,6 @@ static inline int notify_page_fault(struct pt_regs *regs) } return ret; } -#else -static inline int notify_page_fault(struct pt_regs *regs) -{ - return 0; -} -#endif static void __kprobes unhandled_fault(unsigned long address, struct task_struct *tsk, |