diff options
Diffstat (limited to 'arch/powerpc/kernel/kprobes-ftrace.c')
-rw-r--r-- | arch/powerpc/kernel/kprobes-ftrace.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/arch/powerpc/kernel/kprobes-ftrace.c b/arch/powerpc/kernel/kprobes-ftrace.c index 48f675a73cff..1e54ec8ad85f 100644 --- a/arch/powerpc/kernel/kprobes-ftrace.c +++ b/arch/powerpc/kernel/kprobes-ftrace.c @@ -32,8 +32,12 @@ */ int __is_active_jprobe(unsigned long addr) { - struct kprobe *p = kprobe_running(); - return (p && (unsigned long)p->addr == addr) ? 1 : 0; + if (!preemptible()) { + struct kprobe *p = raw_cpu_read(current_kprobe); + return (p && (unsigned long)p->addr == addr) ? 1 : 0; + } + + return 0; } static nokprobe_inline |