[coreboot] [commit] r6516 - trunk/src/arch/x86/init

repository service svn at coreboot.org
Tue Apr 19 03:36:25 CEST 2011

Author: stepan
Date: Tue Apr 19 03:36:24 2011
New Revision: 6516
URL: https://tracker.coreboot.org/trac/coreboot/changeset/6516

Recently the 3 projects using the new AMD reference code have been
failing the check for globals (or statics) in romstage. This causes
ASRock E350M1, AMD Inagua, and AMD Persimmon builds to fail with the
message "Do not use global variables in romstage". The message is
working as intended. It is detecting data declared as 'static' when
'static const' was intended. The code executes correctly because it
never tries to modify the data.

To make reference code updates easy, it is probably best to avoid
modifying the AMD provided code if possible. The following change
bypasses the "Do not use global variables in romstage" check for
the AMD reference code only.

Signed-off-by: Scott Duplichan <scott at notabs.org>
Acked-by: Stefan Reinauer <stefan.reinauer at coreboot.org>


Modified: trunk/src/arch/x86/init/bootblock.ld
--- trunk/src/arch/x86/init/bootblock.ld	Tue Apr 19 03:18:54 2011	(r6515)
+++ trunk/src/arch/x86/init/bootblock.ld	Tue Apr 19 03:36:24 2011	(r6516)
@@ -49,5 +49,6 @@
-	_bogus = ASSERT((SIZEOF(.bss) + SIZEOF(.data)) == 0, "Do not use global variables in romstage");
+	_bogus = ASSERT((SIZEOF(.bss) + SIZEOF(.data)) == 0 || CONFIG_AMD_AGESA, "Do not use global variables in romstage");

More information about the coreboot mailing list