NMI now triggers the debugger
This commit is contained in:
parent
1c88ad598c
commit
09f3e260ff
@ -41,7 +41,7 @@
|
|||||||
|
|
||||||
#define T_SYSCALL 60 /* System Call */
|
#define T_SYSCALL 60 /* System Call */
|
||||||
#define T_CROSSCALL 61 /* Cross Call (IPI) */
|
#define T_CROSSCALL 61 /* Cross Call (IPI) */
|
||||||
#define T_DEBUGIPI 62 /* Kernel Debugger Halt (IPI */
|
#define T_DEBUGIPI 62 /* Kernel Debugger Halt (IPI) */
|
||||||
|
|
||||||
#define T_UNKNOWN 63 /* Unknown Trap */
|
#define T_UNKNOWN 63 /* Unknown Trap */
|
||||||
|
|
||||||
|
@ -148,10 +148,12 @@ trap_entry(TrapFrame *tf)
|
|||||||
// XXX: USE ATOMIC!
|
// XXX: USE ATOMIC!
|
||||||
intStats[tf->vector]++;
|
intStats[tf->vector]++;
|
||||||
|
|
||||||
// Debug NMI (should be T_DEBUGIPI)
|
// Debug NMI
|
||||||
if (tf->vector == T_NMI) {
|
if (tf->vector == T_NMI) {
|
||||||
Debug_HaltIPI(tf);
|
Critical_Enter();
|
||||||
LAPIC_SendEOI();
|
kprintf("Kernel Fault: Vector %d\n", tf->vector);
|
||||||
|
Trap_Dump(tf);
|
||||||
|
Debug_Breakpoint(tf);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -233,6 +235,12 @@ trap_entry(TrapFrame *tf)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Debug IPI
|
||||||
|
if (tf->vector == T_DEBUGIPI) {
|
||||||
|
Debug_HaltIPI(tf);
|
||||||
|
LAPIC_SendEOI();
|
||||||
|
}
|
||||||
|
|
||||||
// Cross calls
|
// Cross calls
|
||||||
if (tf->vector == T_CROSSCALL)
|
if (tf->vector == T_CROSSCALL)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user