Julius Werner has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/31123 )
Change subject: WIP: bootmem: add new memory type for BL31 ......................................................................
Patch Set 7:
(4 comments)
https://review.coreboot.org/#/c/31123/7/src/arch/arm64/tables.c File src/arch/arm64/tables.c:
https://review.coreboot.org/#/c/31123/7/src/arch/arm64/tables.c@27 PS7, Line 27: #define _bl31_size (_ebl31 - _bl31) Please put these three into <symbols.h>
https://review.coreboot.org/#/c/31123/7/src/include/bootmem.h File src/include/bootmem.h:
https://review.coreboot.org/#/c/31123/7/src/include/bootmem.h@40 PS7, Line 40: nit: maybe add "arm64" for clarification
https://review.coreboot.org/#/c/31123/7/src/soc/mediatek/mt8183/include/soc/... File src/soc/mediatek/mt8183/include/soc/memlayout.ld:
https://review.coreboot.org/#/c/31123/7/src/soc/mediatek/mt8183/include/soc/... PS7, Line 51: REGION(bl31 Please define a new BL31() macro for this in <arch/memlayout.h>
https://review.coreboot.org/#/c/31123/7/src/soc/nvidia/tegra210/include/soc/... File src/soc/nvidia/tegra210/include/soc/memlayout.ld:
https://review.coreboot.org/#/c/31123/7/src/soc/nvidia/tegra210/include/soc/... PS7, Line 50: CONFIG_TRUSTZONE_CARVEOUT_SIZE_MB * 1M, 0x1000) ...yeah, you can't do that because memlayout intentionally doesn't let you overlap regions. One solution would be to manually put
_ebl31 = _ettb; _bl31 = _ebl31 - CONFIG_TRUSTZONE_CARVEOUT_SIZE_MB * 1M;
in here. But that's pretty ugly, so maybe you should just treat tegra210 specially and give it its own bootmem_platform_add_ranges() as I mentioned before (without putting BL31 in memlayout).