aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/kernel/hw_breakpoint.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/kernel/hw_breakpoint.c')
-rw-r--r--arch/arm/kernel/hw_breakpoint.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/arm/kernel/hw_breakpoint.c b/arch/arm/kernel/hw_breakpoint.c
index 36cd7680d3d..eef1b1e235a 100644
--- a/arch/arm/kernel/hw_breakpoint.c
+++ b/arch/arm/kernel/hw_breakpoint.c
@@ -622,10 +622,12 @@ int arch_validate_hwbkpt_settings(struct perf_event *bp)
622 * Currently we rely on an overflow handler to take 622 * Currently we rely on an overflow handler to take
623 * care of single-stepping the breakpoint when it fires. 623 * care of single-stepping the breakpoint when it fires.
624 * In the case of userspace breakpoints on a core with V7 debug, 624 * In the case of userspace breakpoints on a core with V7 debug,
625 * we can use the mismatch feature as a poor-man's hardware single-step. 625 * we can use the mismatch feature as a poor-man's hardware
626 * single-step, but this only works for per-task breakpoints.
626 */ 627 */
627 if (WARN_ONCE(!bp->overflow_handler && 628 if (WARN_ONCE(!bp->overflow_handler &&
628 (arch_check_bp_in_kernelspace(bp) || !core_has_mismatch_brps()), 629 (arch_check_bp_in_kernelspace(bp) || !core_has_mismatch_brps()
630 || !bp->hw.bp_target),
629 "overflow handler required but none found")) { 631 "overflow handler required but none found")) {
630 ret = -EINVAL; 632 ret = -EINVAL;
631 } 633 }