From 0b23d47ffd1c87cb41df9e3e1b73cdfddd425dcd Mon Sep 17 00:00:00 2001 From: David Hendricks Date: Mon, 14 Jan 2013 20:58:50 -0800 Subject: armv7: Place reset vector + CBFS header + bootblock dynamically This replaces hard-coded bootblock offsets using the new scheme. The assembler will place the initial branch instruction after BL1, skip 2 aligned chunks, and place the remaining bootblock code after. It will also leave an anchor string, currently 0xdeadbeef which cbfstool will find. Once found, cbfstool will place the master CBFS header at the next aligned offset. Here is how it looks: 0x0000 |--------------| | BL1 | 0x2000 |--------------| | branch | 0x2000 + align |--------------| | CBFS header | 0x2000 + align * 2 |--------------| | bootblock | |--------------| TODO: The option for alignment passed into cbfstool has always been 64. Can we set it to 16 instead? Change-Id: Icbe817cbd8a37f11990aaf060aab77d2dc113cb1 Signed-off-by: David Hendricks Reviewed-on: http://review.coreboot.org/2148 Tested-by: build bot (Jenkins) Reviewed-by: Ronald G. Minnich --- src/arch/armv7/Makefile.inc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/arch/armv7/Makefile.inc') diff --git a/src/arch/armv7/Makefile.inc b/src/arch/armv7/Makefile.inc index a4f57f34c1..cc306335cd 100644 --- a/src/arch/armv7/Makefile.inc +++ b/src/arch/armv7/Makefile.inc @@ -48,8 +48,7 @@ prebuilt-files = $(foreach file,$(cbfs-files), $(call extract_nth,1,$(file))) $(obj)/coreboot.pre1: $(objcbfs)/bootblock.bin $$(prebuilt-files) $(CBFSTOOL) $(CBFSTOOL) $@.tmp create -m armv7 -s $(CONFIG_COREBOOT_ROMSIZE_KB)K \ - -B $(objcbfs)/bootblock.bin -a 64 \ - -o $$(( $(CONFIG_ROM_SIZE) - $(CONFIG_CBFS_SIZE) )) + -B $(objcbfs)/bootblock.bin -a 64 $(prebuild-files) true mv $@.tmp $@ else -- cgit v1.2.3