diff options
author | Philipp Hug <philipp@hug.cx> | 2024-03-01 10:59:56 +0000 |
---|---|---|
committer | ron minnich <rminnich@gmail.com> | 2024-03-04 23:43:46 +0000 |
commit | 8e365396d4274b8656fd5c3bd47e9e8953db7e59 (patch) | |
tree | 63d37b61ba3ee9db79bbf1e1dbdf80eaa45713e7 /src/mainboard | |
parent | f3ae0f0cfb56aae82ff877ee74b9c8e83aee9ab9 (diff) |
riscv/mb/qemu: fix DRAM probing
Current version of qemu raise an exception when accessing invalid
memory. Modify the probing code to temporary redirect the exception
handler like on ARM platform.
Also move saving of the stack frame out to trap_util.S to have all at
the same place for a future rewrite.
TEST=boots to ramstage
Change-Id: I25860f688c7546714f6fdbce8c8f96da6400813c
Signed-off-by: Philipp Hug <philipp@hug.cx>
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/36486
Reviewed-by: ron minnich <rminnich@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/mainboard')
-rw-r--r-- | src/mainboard/emulation/qemu-riscv/Kconfig | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/mainboard/emulation/qemu-riscv/Kconfig b/src/mainboard/emulation/qemu-riscv/Kconfig index d915d6826e..af4416d0c1 100644 --- a/src/mainboard/emulation/qemu-riscv/Kconfig +++ b/src/mainboard/emulation/qemu-riscv/Kconfig @@ -45,7 +45,10 @@ config MAX_CPUS config DRAM_SIZE_MB int - default 32768 + default 16383 + help + Qemu maps MMIO at ALIGN_UP(top_of_mem, 16 * GiB) + To avoid confusing the dram probing algorithm, avoid large dram sizes (16G - 1m) config OPENSBI_PLATFORM string |