12 pushl $0 /* ErrorCode */
15 movl 20(%esp), %ebp /* Eip */
16 movl 16(%esp), %ebx /* Eflags */
18 movl 12(%esp), %ebx /* Cs */
24 pushl $0 /* ExceptionList */
25 pushl $0 /* PreviousMode */
34 /* Clear all breakpoint enables in dr7. */
35 andl $0xFFFF0000, %eax
48 pushl %eax /* TempEsp */
49 pushl %ss /* TempSegSs */
50 pushl $0 /* DebugPointer */
51 pushl $3 /* DebugArgMark (Exception number) */
52 pushl 0x60(%esp) /* DebugEip */
53 pushl %ebp /* DebugEbp */
59 pushl $1 /* FirstChance */
60 pushl %eax /* Push a pointer to the trap frame */
61 pushl $0 /* Context */
62 pushl $0 /* PreviousMode (KernelMode) */
63 pushl $0 /* ExceptionRecord */
64 call _KdbEnterDebuggerException
67 * Pop the arguments and unused portions of the trap frame:
78 * Restore/update debugging registers.
94 * Restore registers including any that might have been changed
95 * inside the debugger.
103 addl $8, %esp /* PreviousMode, ExceptionList */
109 addl $4, %esp /* ErrorCode */
112 * Return to the caller.
117 .globl _KdbpStackSwitchAndCall@8
118 _KdbpStackSwitchAndCall@8:
122 movl 0x8(%esp), %eax /* New stack */
123 movl 0xC(%esp), %ecx /* Function to call */
124 movl %esp, %edx /* Old stack */
133 /* Switch back to old stack */