From b9ecf6458bb1f1c4084a600bb9494b5d1d28b1d7 Mon Sep 17 00:00:00 2001 From: Harrison Mutai Date: Fri, 1 Dec 2023 15:45:05 +0000 Subject: [PATCH] refactor(fvp): reduce max size of HW_CONFIG to 16KB HW_CONFIG is the hardware description consumed primarly by the Linux kernel, and for the FVP platform, TF-A runtime firmware (BL31). Due to both needing it, two copies of this file are made in Trusted DRAM and SRAM. The copy in Trusted DRAM is a workaround stemming from memory constraints in SRAM. We temporarily map the range of memory in Trusted DRAM into BL31 to allow it to consume the configuration. In principle, however, BL31 execution should be limited to SRAM, hence reduce the maximum size of the HW_CONFIG to 16KB in order to accommodate it in SRAM. This is possible since in practice, the HW_CONFIG on FVP is only about 11KB. Change-Id: Idb5dc0637b402562b7177a2b4e2464c4f3f67da7 Signed-off-by: Harrison Mutai --- plat/arm/board/fvp/include/platform_def.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plat/arm/board/fvp/include/platform_def.h b/plat/arm/board/fvp/include/platform_def.h index 512fcea5a..ab1b07f82 100644 --- a/plat/arm/board/fvp/include/platform_def.h +++ b/plat/arm/board/fvp/include/platform_def.h @@ -111,7 +111,7 @@ #define PLAT_SPMC_SHMEM_DATASTORE_SIZE 512 * 1024 /* Define memory configuration for device tree files. */ -#define PLAT_ARM_HW_CONFIG_SIZE U(0x10000) +#define PLAT_ARM_HW_CONFIG_SIZE U(0x4000) #if SPMC_AT_EL3 /*