aboutsummaryrefslogtreecommitdiff
path: root/src/mainboard/emulation/qemu-i440fx/memory.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mainboard/emulation/qemu-i440fx/memory.c')
-rw-r--r--src/mainboard/emulation/qemu-i440fx/memory.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/mainboard/emulation/qemu-i440fx/memory.c b/src/mainboard/emulation/qemu-i440fx/memory.c
index 8245ca24dd..000a0f660d 100644
--- a/src/mainboard/emulation/qemu-i440fx/memory.c
+++ b/src/mainboard/emulation/qemu-i440fx/memory.c
@@ -46,7 +46,15 @@ unsigned long get_top_of_ram(void)
return qemu_get_memory_size() * 1024;
}
+#if !CONFIG_DYNAMIC_CBMEM
struct cbmem_entry *get_cbmem_toc(void)
{
return (struct cbmem_entry *)(get_top_of_ram() - HIGH_MEMORY_SIZE);
}
+#else
+void *cbmem_top(void)
+{
+ /* Top of cbmem is at lowest usable DRAM address below 4GiB. */
+ return (void *)get_top_of_ram();
+}
+#endif