[coreboot] New patch to review for coreboot: 0a3613c Makefile: XIP_ROM_SIZE error is not fatal

Kyösti Mälkki (kyosti.malkki@gmail.com) gerrit at coreboot.org
Fri Mar 16 15:25:06 CET 2012

Kyösti Mälkki (kyosti.malkki at gmail.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/791


commit 0a3613c109beaa5038a43b8bc146720c80aa249b
Author: Kyösti Mälkki <kyosti.malkki at gmail.com>
Date:   Fri Mar 16 07:37:41 2012 +0200

    Makefile: XIP_ROM_SIZE error is not fatal
    Romstage size exceeds XIP_ROM_SIZE on following boards:
    This marks the complete Jenkins build as failed.
    XIP_ROM_SIZE should be increased on these platforms, but only after
    testing on real hardware that they have sufficient cache.
    As a workaround, complete such builds with an unaligned placement of
    romstage in the flash image binary. These should execute, but very
    Change-Id: I4d7c791958e3d518051207ab97deef5890dac6cf
    Signed-off-by: Kyösti Mälkki <kyosti.malkki at gmail.com>
 src/arch/x86/Makefile.inc |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/src/arch/x86/Makefile.inc b/src/arch/x86/Makefile.inc
index 75546f1..da49373 100755
--- a/src/arch/x86/Makefile.inc
+++ b/src/arch/x86/Makefile.inc
@@ -109,6 +109,7 @@ ifeq ($(CONFIG_INCLUDE_CONFIG_FILE),y)
 	mv $@.tmp $@
 	@printf "    CBFSPRINT  $(subst $(obj)/,,$(@))\n\n"
+	if [ -f $(obj)/no_xip ]; then echo "The romstage is larger than XIP size. Please expand the CONFIG_XIP_ROM_SIZE.\n" ; fi
 	$(CBFSTOOL) $@ print
 stripped_vgabios_id = $(call strip_quotes,$(CONFIG_VGA_BIOS_ID))
@@ -346,7 +347,11 @@ $(obj)/coreboot.romstage: $(obj)/coreboot.pre1 $$(romstage-objs) $(obj)/romstage
 	$(CC) -nostdlib -nostartfiles -static -o $(obj)/romstage.elf -L$(obj) -T $(obj)/romstage/ldscript.ld $(romstage-objs)
 	$(OBJCOPY) -O binary $(obj)/romstage.elf $(obj)/romstage.bin
 	printf "CONFIG_ROMBASE = 0x" > $(obj)/location.ld
-	$(CBFSTOOL) $(obj)/coreboot.pre1 locate $(obj)/romstage.bin $(CONFIG_CBFS_PREFIX)/romstage $(CONFIG_XIP_ROM_SIZE) > $(obj)/location.txt || { echo "The romstage is larger than XIP size. Please expand the CONFIG_XIP_ROM_SIZE" ; exit 1; }
+	rm -f $(obj)/no_xip
+	$(CBFSTOOL) $(obj)/coreboot.pre1 locate $(obj)/romstage.bin $(CONFIG_CBFS_PREFIX)/romstage $(CONFIG_XIP_ROM_SIZE) > $(obj)/location.txt || touch $(obj)/no_xip
+	if [ -f $(obj)/no_xip ]; then \
+		$(CBFSTOOL) $(obj)/coreboot.pre1 locate $(obj)/romstage.bin $(CONFIG_CBFS_PREFIX)/romstage $(CONFIG_ROM_SIZE) > $(obj)/location.txt || exit 1 ; \
+	fi
 	cat $(obj)/location.txt >> $(obj)/location.ld
 	printf ';\n' >> $(obj)/location.ld
 	$(CC) -nostdlib -nostartfiles -static -o $(obj)/romstage.elf -L$(obj) -T $(obj)/romstage/ldscript.ld $(romstage-objs)

More information about the coreboot mailing list