From 7777746c40876834c1527689336e43c8381b1921 Mon Sep 17 00:00:00 2001 From: Richard Kuo Date: Thu, 7 Mar 2013 12:03:10 -0600 Subject: Hexagon: add support for single-stepping (v4+) Hardware single-step is only available on v4 and later architectures. Signed-off-by: Richard Kuo --- arch/hexagon/kernel/traps.c | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'arch/hexagon/kernel/traps.c') diff --git a/arch/hexagon/kernel/traps.c b/arch/hexagon/kernel/traps.c index 12164a30e8ff..c2eeeef55335 100644 --- a/arch/hexagon/kernel/traps.c +++ b/arch/hexagon/kernel/traps.c @@ -451,3 +451,14 @@ void do_machcheck(struct pt_regs *regs) /* Halt and catch fire */ __vmstop(); } + +/* + * Treat this like the old 0xdb trap. + */ + +void do_debug_exception(struct pt_regs *regs) +{ + regs->hvmer.vmest &= ~HVM_VMEST_CAUSE_MSK; + regs->hvmer.vmest |= (TRAP_DEBUG << HVM_VMEST_CAUSE_SFT); + do_trap0(regs); +} -- cgit v1.2.3