aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/traps_64.c
diff options
context:
space:
mode:
authorRoland McGrath <roland@redhat.com>2008-01-30 07:30:54 -0500
committerIngo Molnar <mingo@elte.hu>2008-01-30 07:30:54 -0500
commit10faa81e102e2b7695f386812055cd2ef9e44b4c (patch)
treebd21d2094eacca5b07d5ee5977cb0ad57ebc5c02 /arch/x86/kernel/traps_64.c
parent7e9916040b3020d0f36d68bb7512e3b80b623097 (diff)
x86: debugctlmsr arch_has_block_step
This implements user-mode step-until-branch on x86 using the BTF bit in MSR_IA32_DEBUGCTLMSR. It's just like single-step, only less so. Signed-off-by: Roland McGrath <roland@redhat.com> Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86/kernel/traps_64.c')
-rw-r--r--arch/x86/kernel/traps_64.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/arch/x86/kernel/traps_64.c b/arch/x86/kernel/traps_64.c
index 874aca397b02..610a64d6bdf0 100644
--- a/arch/x86/kernel/traps_64.c
+++ b/arch/x86/kernel/traps_64.c
@@ -850,6 +850,12 @@ asmlinkage void __kprobes do_debug(struct pt_regs * regs,
850 850
851 get_debugreg(condition, 6); 851 get_debugreg(condition, 6);
852 852
853 /*
854 * The processor cleared BTF, so don't mark that we need it set.
855 */
856 clear_tsk_thread_flag(tsk, TIF_DEBUGCTLMSR);
857 tsk->thread.debugctlmsr = 0;
858
853 if (notify_die(DIE_DEBUG, "debug", regs, condition, error_code, 859 if (notify_die(DIE_DEBUG, "debug", regs, condition, error_code,
854 SIGTRAP) == NOTIFY_STOP) 860 SIGTRAP) == NOTIFY_STOP)
855 return; 861 return;