coreboot-kgpe-d16/src/soc/nvidia/tegra132
Julius Werner efcee767de CBFS: Automate ROM image layout and remove hardcoded offsets
Non-x86 boards currently need to hardcode the position of their CBFS
master header in a Kconfig. This is very brittle because it is usually
put in between the bootblock and the first CBFS entry, without any
checks to guarantee that it won't overlap either of those. It is not fun
to debug random failures that move and disappear with tiny alignment
changes because someone decided to write "ORBC1112" over some part of
your data section (in a way that is not visible in the symbolized .elf
binaries, only in the final image). This patch seeks to prevent those
issues and reduce the need for manual configuration by making the image
layout a completely automated part of cbfstool.

Since automated placement of the CBFS header means we can no longer
hardcode its position into coreboot, this patch takes the existing x86
solution of placing a pointer to the header at the very end of the
CBFS-managed section of the ROM and generalizes it to all architectures.
This is now even possible with the read-only/read-write split in
ChromeOS, since coreboot knows how large that section is from the
CBFS_SIZE Kconfig (which is by default equal to ROM_SIZE, but can be
changed on systems that place other data next to coreboot/CBFS in ROM).

Also adds a feature to cbfstool that makes the -B (bootblock file name)
argument on image creation optional, since we have recently found valid
use cases for CBFS images that are not the first boot medium of the
device (instead opened by an earlier bootloader that can already
interpret CBFS) and therefore don't really need a bootblock.

BRANCH=None
BUG=None
TEST=Built and booted on Veyron_Pinky, Nyan_Blaze and Falco.

Change-Id: Ib715bb8db258e602991b34f994750a2d3e2d5adf
Signed-off-by: Patrick Georgi <pgeorgi@chromium.org>
Original-Commit-Id: e9879c0fbd57f105254c54bacb3e592acdcad35c
Original-Change-Id: Ifcc755326832755cfbccd6f0a12104cba28a20af
Original-Signed-off-by: Julius Werner <jwerner@chromium.org>
Original-Reviewed-on: https://chromium-review.googlesource.com/229975
Reviewed-on: http://review.coreboot.org/9620
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
2015-04-14 09:01:27 +02:00
..
include/soc arm: Add bootblock_mainboard_early_init() for pre-console initialization 2015-04-13 17:21:17 +02:00
jdi_25x18_display tegra132: Add dsi driver 2015-04-10 20:43:15 +02:00
lp0 tegra132: configure debug uart to 115200n8 in tegra_lp0_resume 2015-04-09 14:40:14 +02:00
32bit_reset.S tegra132: refactor cpu startup code 2015-03-27 08:03:39 +01:00
addressmap.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
bootblock.c arm: Add bootblock_mainboard_early_init() for pre-console initialization 2015-04-13 17:21:17 +02:00
bootblock_asm.S New mechanism to define SRAM/memory map with automatic bounds checking 2015-04-06 22:05:01 +02:00
cbfs.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
cbmem.c tegra132: remove framebuffer reservation 2015-04-04 15:03:37 +02:00
ccplex.c t132: add RAM repair to cluster 1 2015-04-13 12:19:33 +02:00
chip.h ryu: display: Split dc functions from dsi display code 2015-04-13 17:04:14 +02:00
clock.c tegra132: rename clock_display() to clock_configure_plld() 2015-04-10 20:44:41 +02:00
cpu.c tegra132: prepare cpu startup in psci 2015-04-10 20:46:16 +02:00
cpu_lib.S tegra132: implement smp_processor_id() 2015-03-27 08:03:53 +01:00
dc.c ryu: display: Split dc functions from dsi display code 2015-04-13 17:04:14 +02:00
dma.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
dp.c rush: Add and select DO_SOR_INIT config option 2015-04-13 17:04:51 +02:00
dsi.c ryu: display: Move display api to mainboard 2015-04-13 17:04:31 +02:00
flow_ctrl.c tegra132: psci: add cpu_on/off support 2015-04-10 20:48:01 +02:00
funitcfg.c t132: Add I2S1 support to funit 2015-04-13 16:43:46 +02:00
gic.c tegra132: use generic GIC driver 2015-03-28 07:05:06 +01:00
i2c.c tegra132: Add I2C1 support to funit 2015-04-10 12:02:24 +02:00
i2c6.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
Kconfig CBFS: Automate ROM image layout and remove hardcoded offsets 2015-04-14 09:01:27 +02:00
maincpu.S tegra132: Enable bootblock support in tegra132 including UART support 2015-03-02 21:17:21 +01:00
Makefile.inc rush: Add and select DO_SOR_INIT config option 2015-04-13 17:04:51 +02:00
mipi-phy.c tegra132: Add dsi driver 2015-04-10 20:43:15 +02:00
mipi.c tegra132: Add dsi driver 2015-04-10 20:43:15 +02:00
mipi_dsi.c tegra132: Add dsi driver 2015-04-10 20:43:15 +02:00
mmu_operations.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
monotonic_timer.c coreboot t132,rush: Add mainboard specific bootblock_init 2015-03-04 18:15:44 +01:00
padconfig.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
power.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
psci.c tegra132: psci: add cpu_on/off support 2015-04-10 20:48:01 +02:00
ramstage.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
reset.c tegra132: use pre-existing reset API 2015-03-25 22:31:54 +01:00
romstage.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
romstage_asm.S New mechanism to define SRAM/memory map with automatic bounds checking 2015-04-06 22:05:01 +02:00
sdram.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
sdram_lp0.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
secmon.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
soc.c tegra132: always bring up PLLD 2015-04-10 20:44:47 +02:00
spi.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
stack.S New mechanism to define SRAM/memory map with automatic bounds checking 2015-04-06 22:05:01 +02:00
uart.c tegra132: Change all SoC headers to <soc/headername.h> system 2015-04-08 09:26:14 +02:00
verstage.c t132: Add vboot2 support 2015-04-08 20:16:21 +02:00