[coreboot] [PATCH]es to get normal image to work again with CBFS
Patrick Georgi
patrick at georgi-clan.de
Fri Jun 5 19:37:26 CEST 2009
Hi,
as promised, here's a follow-up to my mail from 2009-05-31. The patch
from back then (also reproduced here) breaks CBFS using boards, as
switching to CBFS requires some more changes now. The benefit is that
the normal image works again, which was broken with CBFS so far. The
patches here fix the breakage for the already transitioned boards.
20090531-use-coreboot.rom-for-cbfs: Change the CBFS build process to use
coreboot.rom instead of coreboot.strip, which fixes the calculation of
the entry point of the normal image. (same patch as in the old mail, and
Acked by myles)
20090605-3-fix-abuild-of-m2v-mx-se-with-crosscompiler: Properly use
CROSS_COMPILE, so abuild uses i386-elf-gcc as compiler if it needs to.
20090605-4-move-CONFIG_CBFS-to-Options-lb: hp/dl145_g3 defined
CONFIG_CBFS in the targets/* files, move to Options.lb like for every
other CBFS-using board
20090605-5-fix-via-vt8454c: Fix up via/vt8454c after the 20090531 patch
20090605-6-fix-kontron-986lcd-m: Likewise for kontron/986lcd-m
20090605-7-fix-emulation-qemu-x86: Likewise for emulation/qemu-x86
20090605-8-fix-hp-dl145-g3: Likewise for hp/dl145_g3
The 20090605-[5678]-* patches give some indication on how to switch a
board over to CBFS support. It's not as easy as without the 20090531
patch, but at least it works correctly then:
For targets that use the src/config/*calculation.lb files, it's quite easy:
1. define FALLBACK_SIZE to ROM_IMAGE_SIZE (both normal and fallback are
of that size now, that kludge can be dropped after non-CBFS is dropped)
2. drop most size definitions from the targets/*/*/Config*lb, except
ROM_SIZE (the total size of the image)
3. ROM_IMAGE_SIZE must be set to the intended size of the up-to-raminit
stage of coreboot (coreboot_ram is loaded from CBFS).
Usually, 64kb is enough, and choosing smaller values only makes
configuring the XIP range harder.
For boards with coreboot_apc image (AMD stuff mostly), you also have to
remove "ldscript /arch/i386/init/ldscript_apc.lb" from the mainboard's
Config.lb (not shown in this patch set, as none of these boards uses
it). coreboot_apc also resides in CBFS now, so this link hack in not
required anymore.
With this, I think CBFS has no regressions over the old style rom image
layout anymore, so moving everything over to using CBFS would be a nice
next step, as lots of stuff in the build system could disappear after that.
Regards,
Patrick
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 20090531-use-coreboot.rom-for-cbfs
URL: <http://www.coreboot.org/pipermail/coreboot/attachments/20090605/f7406cfb/attachment.ksh>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 20090605-3-fix-abuild-of-m2v-mx-se-with-crosscompiler
URL: <http://www.coreboot.org/pipermail/coreboot/attachments/20090605/f7406cfb/attachment-0001.ksh>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 20090605-4-move-CONFIG_CBFS-to-Options-lb
URL: <http://www.coreboot.org/pipermail/coreboot/attachments/20090605/f7406cfb/attachment-0002.ksh>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 20090605-5-fix-via-vt8454c
URL: <http://www.coreboot.org/pipermail/coreboot/attachments/20090605/f7406cfb/attachment-0003.ksh>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 20090605-6-fix-kontron-986lcd-m
URL: <http://www.coreboot.org/pipermail/coreboot/attachments/20090605/f7406cfb/attachment-0004.ksh>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 20090605-7-fix-emulation-qemu-x86
URL: <http://www.coreboot.org/pipermail/coreboot/attachments/20090605/f7406cfb/attachment-0005.ksh>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 20090605-8-fix-hp-dl145-g3
URL: <http://www.coreboot.org/pipermail/coreboot/attachments/20090605/f7406cfb/attachment-0006.ksh>
More information about the coreboot
mailing list