diff options
author | Andreas Kling <kling@serenityos.org> | 2021-03-04 17:50:05 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-03-04 18:25:01 +0100 |
commit | adb2e6be5f2858076f7c226c1d986db464fd4f0b (patch) | |
tree | 464926708344545ee1942b96d991570c163a7bbc /Kernel/Thread.cpp | |
parent | aae91dda66f99cce81f6d21ffad46528d69a2194 (diff) | |
download | serenity-adb2e6be5f2858076f7c226c1d986db464fd4f0b.zip |
Kernel: Make the kernel compile & link for x86_64
It's now possible to build the whole kernel with an x86_64 toolchain.
There's no bootstrap code so it doesn't work yet (obviously.)
Diffstat (limited to 'Kernel/Thread.cpp')
-rw-r--r-- | Kernel/Thread.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Kernel/Thread.cpp b/Kernel/Thread.cpp index bd50f16dc9..d19bcbd9b8 100644 --- a/Kernel/Thread.cpp +++ b/Kernel/Thread.cpp @@ -795,12 +795,12 @@ DispatchSignalResult Thread::dispatch_signal(u8 signal) auto setup_stack = [&](RegisterState& state) { #if ARCH(I386) FlatPtr* stack = &state.userspace_esp; -#elif ARCH(X86_64) - FlatPtr* stack = &state.userspace_esp; -#endif FlatPtr old_esp = *stack; FlatPtr ret_eip = state.eip; FlatPtr ret_eflags = state.eflags; +#elif ARCH(X86_64) + FlatPtr* stack = &state.userspace_esp; +#endif #if SIGNAL_DEBUG klog() << "signal: setting up user stack to return to eip: " << String::format("%p", (void*)ret_eip) << " esp: " << String::format("%p", (void*)old_esp); |