From fa3bc049f5ca51eeb35fafb61f043d5a54f30c14 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ky=C3=B6sti=20M=C3=A4lkki?= Date: Thu, 31 Mar 2022 07:40:10 +0300 Subject: CBMEM: Change declarations for initialization hooks MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit There are efforts to have bootflows that do not follow a traditional bootblock-romstage-postcar-ramstage model. As part of that CBMEM initialisation hooks will need to move from romstage to bootblock. The interface towards platforms and drivers will change to use one of CBMEM_CREATION_HOOK() or CBMEM_READY_HOOK(). Former will only be called in the first stage with CBMEM available. Change-Id: Ie24bf4e818ca69f539196c3a814f3c52d4103d7e Signed-off-by: Kyösti Mälkki Reviewed-on: https://review.coreboot.org/c/coreboot/+/63375 Tested-by: build bot (Jenkins) Reviewed-by: Arthur Heymans Reviewed-by: Julius Werner Reviewed-by: Raul Rangel --- src/mainboard/google/gale/mmu.c | 2 +- src/mainboard/google/storm/mmu.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src/mainboard') diff --git a/src/mainboard/google/gale/mmu.c b/src/mainboard/google/gale/mmu.c index 3b9917c9a9..1d8bd3370a 100644 --- a/src/mainboard/google/gale/mmu.c +++ b/src/mainboard/google/gale/mmu.c @@ -28,7 +28,7 @@ void setup_dram_mappings(enum dram_state dram) /* Map DMA memory */ mmu_config_range(DMA_START, DMA_SIZE, DCACHE_OFF); /* Mark cbmem backing store as ready. */ - if (ENV_ROMSTAGE) + if (ENV_CREATES_CBMEM) ipq_cbmem_backing_store_ready(); } else { mmu_disable_range(DRAM_START, DRAM_SIZE); diff --git a/src/mainboard/google/storm/mmu.c b/src/mainboard/google/storm/mmu.c index 37b4654b1b..b482f9be2e 100644 --- a/src/mainboard/google/storm/mmu.c +++ b/src/mainboard/google/storm/mmu.c @@ -25,7 +25,7 @@ void setup_dram_mappings(enum dram_state dram) mmu_config_range(DRAM_START, DRAM_SIZE, DCACHE_WRITEBACK); /* Map DMA memory */ mmu_config_range(DMA_START, DMA_SIZE, DCACHE_OFF); - if (ENV_ROMSTAGE) + if (ENV_CREATES_CBMEM) /* Mark cbmem backing store as ready. */ ipq_cbmem_backing_store_ready(); } else { -- cgit v1.2.3