summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorKyösti Mälkki <kyosti.malkki@gmail.com>2014-12-26 13:28:35 +0200
committerKyösti Mälkki <kyosti.malkki@gmail.com>2014-12-28 19:56:58 +0100
commitc7c02673e45a1c35ee020049c3dcf6da7e7ed1f0 (patch)
treee9b3879081e37e192b14714598413233163935d9 /src/lib
parentd4b1139e289d8a786caee42e8ba198dd9a4538f4 (diff)
downloadcoreboot-c7c02673e45a1c35ee020049c3dcf6da7e7ed1f0.tar.xz
RELOCATABLE_RAMSTAGE: Fix weak symbols with ramstage_cache
We had NULL reference with cache_loaded_ramstage() if CACHE_RELOCATED_RAMSTAGE_OUTSIDE_CBMEM was not set so boot never proceeded to ramstage. Cache implementation outside CBMEM provides means for platform-specific location so there is no need of weak attributes here. Change-Id: I1eb1a713896395c424fde23252c374f9065fe74d Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: http://review.coreboot.org/7954 Tested-by: build bot (Jenkins) Reviewed-by: Edward O'Callaghan <eocallaghan@alterapraxis.com>
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/Makefile.inc2
-rw-r--r--src/lib/ramstage_cache.c6
2 files changed, 3 insertions, 5 deletions
diff --git a/src/lib/Makefile.inc b/src/lib/Makefile.inc
index b7daea116d..327c9f2503 100644
--- a/src/lib/Makefile.inc
+++ b/src/lib/Makefile.inc
@@ -86,7 +86,7 @@ romstage-y += hexdump.c
romstage-$(CONFIG_REG_SCRIPT) += reg_script.c
ramstage-$(CONFIG_REG_SCRIPT) += reg_script.c
-romstage-$(CONFIG_CACHE_RELOCATED_RAMSTAGE_OUTSIDE_CBMEM) += ramstage_cache.c
+romstage-$(CONFIG_RELOCATABLE_RAMSTAGE) += ramstage_cache.c
smm-y += cbfs.c cbfs_core.c memcmp.c
smm-$(CONFIG_COMPILER_GCC) += gcc.c
diff --git a/src/lib/ramstage_cache.c b/src/lib/ramstage_cache.c
index 0f7273a961..814d807713 100644
--- a/src/lib/ramstage_cache.c
+++ b/src/lib/ramstage_cache.c
@@ -96,8 +96,7 @@ void *load_cached_ramstage(struct romstage_handoff *handoff,
/* Cache relocated ramstage in CBMEM. */
-void __attribute__((weak))
-cache_loaded_ramstage(struct romstage_handoff *handoff,
+void cache_loaded_ramstage(struct romstage_handoff *handoff,
const struct cbmem_entry *ramstage, void *entry_point)
{
uint32_t ramstage_size;
@@ -120,8 +119,7 @@ cache_loaded_ramstage(struct romstage_handoff *handoff,
ramstage_size);
}
-void * __attribute__((weak))
-load_cached_ramstage(struct romstage_handoff *handoff,
+void *load_cached_ramstage(struct romstage_handoff *handoff,
const struct cbmem_entry *ramstage)
{
const struct cbmem_entry *entry_cache;