summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/lib/Makefile.inc4
-rw-r--r--src/lib/cbmem_common.c (renamed from src/lib/cbmem_info.c)4
2 files changed, 7 insertions, 1 deletions
diff --git a/src/lib/Makefile.inc b/src/lib/Makefile.inc
index 05010914ce..ec3c2f4cc4 100644
--- a/src/lib/Makefile.inc
+++ b/src/lib/Makefile.inc
@@ -81,7 +81,9 @@ else
ramstage-y += cbmem.c
romstage-y += cbmem.c
endif # CONFIG_DYNAMIC_CBMEM
-ramstage-y += cbmem_info.c
+
+romstage-y += cbmem_common.c
+ramstage-y += cbmem_common.c
ramstage-y += hexdump.c
romstage-y += hexdump.c
diff --git a/src/lib/cbmem_info.c b/src/lib/cbmem_common.c
index 7b1168dc4e..a800173ffd 100644
--- a/src/lib/cbmem_info.c
+++ b/src/lib/cbmem_common.c
@@ -20,6 +20,8 @@
#include <cbmem.h>
#include <stdlib.h>
+#ifndef __PRE_RAM__
+
static const struct cbmem_id_to_name cbmem_ids[] = { CBMEM_ID_TO_NAME_TABLE };
void cbmem_print_entry(int n, u32 id, u64 base, u64 size)
@@ -43,3 +45,5 @@ void cbmem_print_entry(int n, u32 id, u64 base, u64 size)
printk(BIOS_DEBUG, "%08llx ", base);
printk(BIOS_DEBUG, "%08llx\n", size);
}
+
+#endif /* !__PRE_RAM__ */