aboutsummaryrefslogtreecommitdiff
path: root/arch/x86/kernel/kprobes.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86/kernel/kprobes.c')
-rw-r--r--arch/x86/kernel/kprobes.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/arch/x86/kernel/kprobes.c b/arch/x86/kernel/kprobes.c
index 16ae9610f6f..ecee3d23fef 100644
--- a/arch/x86/kernel/kprobes.c
+++ b/arch/x86/kernel/kprobes.c
@@ -490,9 +490,13 @@ static int __kprobes reenter_kprobe(struct kprobe *p, struct pt_regs *regs,
/* A probe has been hit in the codepath leading up
* to, or just after, single-stepping of a probed
* instruction. This entire codepath should strictly
- * reside in .kprobes.text section. Raise a warning
- * to highlight this peculiar case.
+ * reside in .kprobes.text section.
+ * Raise a BUG or we'll continue in an endless
+ * reentering loop and eventually a stack overflow.
*/
+ arch_disarm_kprobe(p);
+ dump_kprobe(p);
+ BUG();
}
default:
/* impossible cases */