[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:
Justin C. Miller
2022-03-13 17:54:27 -07:00
parent 5c3943bf38
commit 24f324552a

View File

@@ -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