Pass CPU state as a pointer

Previously CPU statue was passed on the stack, but the compiler is
allowed to clobber values passed to it on the stack in the SysV x86 ABI.
So now leave the state on the stack but pass a pointer to it into the
ISR functions.
This commit is contained in:
Justin C. Miller
2019-02-07 17:47:42 -08:00
parent 79711be46a
commit 8c32471e0d
5 changed files with 39 additions and 37 deletions

View File

@@ -16,5 +16,5 @@ enum class syscall : uint64_t
};
void syscall_enable();
uintptr_t syscall_dispatch(uintptr_t, const cpu_state &);
uintptr_t syscall_dispatch(uintptr_t, cpu_state &);