Skip to content

Commit

Permalink
[S390] use kprobes_built_in() in mm/fault code
Browse files Browse the repository at this point in the history
Use kprobes_built_in() to avoid ifdefs like most other architectures do.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
  • Loading branch information
Heiko Carstens authored and Martin Schwidefsky committed Feb 26, 2010
1 parent 52499f4 commit 22e0a04
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions arch/s390/mm/fault.c
Original file line number Diff line number Diff line change
Expand Up @@ -60,15 +60,13 @@ static inline int notify_page_fault(struct pt_regs *regs)
{
int ret = 0;

#ifdef CONFIG_KPROBES
/* 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, 14))
ret = 1;
preempt_enable();
}
#endif
return ret;
}

Expand Down

0 comments on commit 22e0a04

Please sign in to comment.