1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-28 19:15:09 +00:00

Kernel: Take some baby steps towards x86_64

Make more of the kernel compile in 64-bit mode, and make some things
pointer-size-agnostic (by using FlatPtr.)

There's a lot of work to do here before the kernel will even compile.
This commit is contained in:
Andreas Kling 2021-02-25 16:18:36 +01:00
parent eb08a0edd5
commit 8f70528f30
12 changed files with 187 additions and 118 deletions

View file

@ -260,6 +260,7 @@ Process::~Process()
extern void signal_trampoline_dummy();
void signal_trampoline_dummy()
{
#if ARCH(I386)
// The trampoline preserves the current eax, pushes the signal code and
// then calls the signal handler. We do this because, when interrupting a
// blocking syscall, that syscall may return some special error code in eax;
@ -280,6 +281,9 @@ void signal_trampoline_dummy()
"int 0x82\n" // sigreturn syscall
"asm_signal_trampoline_end:\n"
".att_syntax" ::"i"(Syscall::SC_sigreturn));
#else
// FIXME: Implement trampoline for other architectures.
#endif
}
extern "C" void asm_signal_trampoline(void);