diff options
-rw-r--r-- | arch/sh/kernel/hw_breakpoint.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/arch/sh/kernel/hw_breakpoint.c b/arch/sh/kernel/hw_breakpoint.c index 75b8c471120f..022d8ed66bd6 100644 --- a/arch/sh/kernel/hw_breakpoint.c +++ b/arch/sh/kernel/hw_breakpoint.c | |||
@@ -398,9 +398,18 @@ BUILD_TRAP_HANDLER(breakpoint) | |||
398 | int __kprobes hw_breakpoint_exceptions_notify(struct notifier_block *unused, | 398 | int __kprobes hw_breakpoint_exceptions_notify(struct notifier_block *unused, |
399 | unsigned long val, void *data) | 399 | unsigned long val, void *data) |
400 | { | 400 | { |
401 | struct die_args *args = data; | ||
402 | |||
401 | if (val != DIE_BREAKPOINT) | 403 | if (val != DIE_BREAKPOINT) |
402 | return NOTIFY_DONE; | 404 | return NOTIFY_DONE; |
403 | 405 | ||
406 | /* | ||
407 | * If the breakpoint hasn't been triggered by the UBC, it's | ||
408 | * probably from a debugger, so don't do anything more here. | ||
409 | */ | ||
410 | if (args->trapnr != 0x1e0) | ||
411 | return NOTIFY_DONE; | ||
412 | |||
404 | return hw_breakpoint_handler(data); | 413 | return hw_breakpoint_handler(data); |
405 | } | 414 | } |
406 | 415 | ||