soc/mediatek/mt8188: Support loading OP-TEE via an SMC
This patch adds compilation flags to BL31 to support loading OP-TEE via an SMC from rootfs. This patch also reserves 80MB memory space for running the OP-TEE image. BUG=b:246837563 TEST=emerge-geralt coreboot Change-Id: Ic38c8beb59c090ae56c5be6821dd8625435609e9 Signed-off-by: Kiwi Liu <kiwi.liu@mediatek.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/78801 Reviewed-by: Kiwi Liu <kiwi.liu@mediatek.corp-partner.google.com> Reviewed-by: Yidi Lin <yidilin@google.com> Reviewed-by: Yu-Ping Wu <yupingso@google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
parent
32ea2abe3b
commit
4bd12361dc
|
@ -22,6 +22,7 @@ config VBOOT
|
|||
select VBOOT_STARTS_IN_BOOTBLOCK
|
||||
select VBOOT_SEPARATE_VERSTAGE
|
||||
select VBOOT_RETURN_FROM_VERSTAGE
|
||||
select VBOOT_DEFINE_WIDEVINE_COUNTERS
|
||||
|
||||
config DPM_DM_FIRMWARE
|
||||
string
|
||||
|
|
|
@ -58,7 +58,8 @@ ramstage-y += ../common/sspm.c
|
|||
ramstage-y += ../common/tps65132s.c
|
||||
ramstage-y += ../common/usb.c usb.c
|
||||
|
||||
BL31_MAKEARGS += PLAT=mt8188
|
||||
BL31_MAKEARGS += PLAT=mt8188 SPD=opteed
|
||||
BL31_MAKEARGS += OPTEE_ALLOW_SMC_LOAD=1 PLAT_XLAT_TABLES_DYNAMIC=1
|
||||
|
||||
CPPFLAGS_common += -Isrc/soc/mediatek/mt8188/include
|
||||
CPPFLAGS_common += -Isrc/soc/mediatek/common/dp/include
|
||||
|
|
|
@ -14,10 +14,14 @@
|
|||
#include <soc/sspm.h>
|
||||
#include <symbols.h>
|
||||
|
||||
#define OPTEE_ADDRESS 0x43000000
|
||||
#define OPTEE_SIZE (80 * MiB)
|
||||
|
||||
void bootmem_platform_add_ranges(void)
|
||||
{
|
||||
if (CONFIG(MTK_DFD))
|
||||
bootmem_add_range(DFD_DUMP_ADDRESS, DFD_DUMP_SIZE, BM_MEM_RESERVED);
|
||||
bootmem_add_range(OPTEE_ADDRESS, OPTEE_SIZE, BM_MEM_RESERVED);
|
||||
}
|
||||
|
||||
static void soc_read_resources(struct device *dev)
|
||||
|
|
Loading…
Reference in New Issue