mirror of
https://github.com/justinian/jsix.git
synced 2025-12-09 16:04:32 -08:00
[kernel] Get rid of fake stack frame in isr_prelude
The isr_prelude (and its IRQ equivalent) had been pushing RIP and RBP in order to create a fake stack frame. This was in an effor to make GDB display tracebacks more reliably, but GDB has other reasons for being finnicky about stack frames, so this was just wasted. This commit gets rid of it to make looking at the stack clearer.
This commit is contained in:
@@ -13,13 +13,6 @@ isr_handler_prelude:
|
||||
check_swap_gs
|
||||
|
||||
mov rdi, rsp
|
||||
mov rsi, rsp
|
||||
|
||||
mov rax, [rsp + REGS.rip]
|
||||
push rax
|
||||
|
||||
push rbp
|
||||
mov rbp, rsp
|
||||
|
||||
call isr_handler
|
||||
jmp isr_handler_return
|
||||
@@ -38,21 +31,12 @@ irq_handler_prelude:
|
||||
mov rdi, rsp
|
||||
mov rsi, rsp
|
||||
|
||||
mov rax, [rsp + REGS.rip]
|
||||
push rax
|
||||
|
||||
push rbp
|
||||
mov rbp, rsp
|
||||
|
||||
call irq_handler
|
||||
; fall through to isr_handler_return
|
||||
.end:
|
||||
|
||||
global isr_handler_return:function (isr_handler_return.end - isr_handler_return)
|
||||
isr_handler_return:
|
||||
pop rbp
|
||||
pop rax ; get rid of the manufactured stack frame
|
||||
|
||||
check_swap_gs
|
||||
pop_all
|
||||
|
||||
|
||||
Reference in New Issue
Block a user