[metal] Ensure DF is clear when calling C from exception handler

This commit is contained in:
tkchia 2023-11-05 22:28:06 +00:00
parent a12ad17291
commit 9939a5d207

View file

@ -92,6 +92,7 @@ __excep0_isr:
mov %eax,%ss mov %eax,%ss
mov %eax,%ds mov %eax,%ds
mov %eax,%es mov %eax,%es
cld # make sure DF is reset, for C code
ezlea .excep_msg,di # stack should be 16-byte aligned now ezlea .excep_msg,di # stack should be 16-byte aligned now
xor %eax,%eax # kprintf is variadic, remember to xor %eax,%eax # kprintf is variadic, remember to
# pass no. of vector regs. used (= 0) # pass no. of vector regs. used (= 0)