sparc: move kernel to a lower address

The openboot mmu code does not like addresses above 4GB, so load the
kernel to a lower address. It doesn't really matter anyway, because on
sparc the kernel normally lives in a separate address space and uses
special instructions to access userland memory.

See #19597 for details, further changes will be needed here.

Change-Id: Iac6901f275667efef5e64d059daf4c96032a7baf
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3573
Reviewed-by: Adrien Destugues <[email protected]>
Tested-by: Commit checker robot <[email protected]>
This commit is contained in:
PulkoMandy
2025-06-11 06:40:13 +00:00
committed by Adrien Destugues
parent 5ac839cb94
commit 26bedc8f4e
2 changed files with 6 additions and 2 deletions
@@ -9,7 +9,11 @@
#include <arch/cpu.h>
// memory layout
#define KERNEL_LOAD_BASE_64_BIT 0xffffffff80000000ll
// FIXME: On sparc, the kernel should live in an independent address space,
// and does not share addresses with userspace. So, a lot of this doesn't
// really make sense. See #19597 for discussion.
// The consequence is that IS_USER_MEMORY cannot work in the way we need.
#define KERNEL_LOAD_BASE_64_BIT 0x80000000ll
// Base of the kernel address space.
// KERNEL_BASE is the base of the kernel address space. This differs from the