X-Git-Url: http://ftp.safe.ca/?a=blobdiff_plain;f=arch%2Fx86%2Fkernel%2Fkgdb.c;h=f47f0eb886b8ddeab27ec8a8fd319801c45ef503;hb=c6f31932d0a1d2b13952f506ebc92675e2d8df80;hp=7d651adcb22273467fd54a07cc47d91bd2ca1c40;hpb=64e9ee3095b61d0300ea548216a57d2536611309;p=safe%2Fjmp%2Flinux-2.6 diff --git a/arch/x86/kernel/kgdb.c b/arch/x86/kernel/kgdb.c index 7d651ad..f47f0eb 100644 --- a/arch/x86/kernel/kgdb.c +++ b/arch/x86/kernel/kgdb.c @@ -46,11 +46,7 @@ #include #include -#ifdef CONFIG_X86_32 -# include -#else -# include -#endif +#include /* * Put the error code here just in case the user cares: @@ -370,15 +366,17 @@ int kgdb_arch_handle_exception(int e_vector, int signo, int err_code, ptr = &remcomInBuffer[1]; if (kgdb_hex2long(&ptr, &addr)) linux_regs->ip = addr; + case 'D': + case 'k': newPC = linux_regs->ip; /* clear the trace bit */ - linux_regs->flags &= ~TF_MASK; + linux_regs->flags &= ~X86_EFLAGS_TF; atomic_set(&kgdb_cpu_doing_single_step, -1); /* set the trace bit if we're stepping */ if (remcomInBuffer[0] == 's') { - linux_regs->flags |= TF_MASK; + linux_regs->flags |= X86_EFLAGS_TF; kgdb_single_step = 1; if (kgdb_contthread) { atomic_set(&kgdb_cpu_doing_single_step, @@ -480,6 +478,8 @@ static int __kgdb_notify(struct die_args *args, unsigned long cmd) if (kgdb_handle_exception(args->trapnr, args->signr, args->err, regs)) return NOTIFY_DONE; + /* Must touch watchdog before return to normal operation */ + touch_nmi_watchdog(); return NOTIFY_STOP; }