mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-16 17:44:19 +00:00
Merge changes from topic "dualroot_dtb" into integration
* changes: refactor(fvp): add CoT desc dtsi feat(arm): add COT_DESC_IN_DTB option for Dualroot feat(fvp): add Dualroot CoT in DTB support feat(dt-bindings): introduce Dualroot CoT DTB
This commit is contained in:
commit
c4b215ff0b
4 changed files with 337 additions and 8 deletions
314
fdts/dualroot_cot_descriptors.dtsi
Normal file
314
fdts/dualroot_cot_descriptors.dtsi
Normal file
|
@ -0,0 +1,314 @@
|
|||
/*
|
||||
* Copyright (c) 2024, Arm Limited. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
||||
#include <tools_share/dualroot_oid.h>
|
||||
#include <common/tbbr/tbbr_img_def.h>
|
||||
#include <common/nv_cntr_ids.h>
|
||||
|
||||
cot {
|
||||
manifests {
|
||||
compatible = "arm, cert-descs";
|
||||
|
||||
trusted_boot_fw_cert: trusted_boot_fw_cert {
|
||||
root-certificate;
|
||||
image-id =<TRUSTED_BOOT_FW_CERT_ID>;
|
||||
antirollback-counter = <&trusted_nv_counter>;
|
||||
|
||||
tb_fw_hash: tb_fw_hash {
|
||||
oid = TRUSTED_BOOT_FW_HASH_OID;
|
||||
};
|
||||
tb_fw_config_hash: tb_fw_config_hash {
|
||||
oid = TRUSTED_BOOT_FW_CONFIG_HASH_OID;
|
||||
};
|
||||
hw_config_hash: hw_config_hash {
|
||||
oid = HW_CONFIG_HASH_OID;
|
||||
};
|
||||
fw_config_hash: fw_config_hash {
|
||||
oid = FW_CONFIG_HASH_OID;
|
||||
};
|
||||
};
|
||||
|
||||
trusted_key_cert: trusted_key_cert {
|
||||
root-certificate;
|
||||
image-id = <TRUSTED_KEY_CERT_ID>;
|
||||
antirollback-counter = <&trusted_nv_counter>;
|
||||
|
||||
trusted_world_pk: trusted_world_pk {
|
||||
oid = TRUSTED_WORLD_PK_OID;
|
||||
};
|
||||
};
|
||||
|
||||
scp_fw_key_cert: scp_fw_key_cert {
|
||||
image-id = <SCP_FW_KEY_CERT_ID>;
|
||||
parent = <&trusted_key_cert>;
|
||||
signing-key = <&trusted_world_pk>;
|
||||
antirollback-counter = <&trusted_nv_counter>;
|
||||
|
||||
scp_fw_content_pk: scp_fw_content_pk {
|
||||
oid = SCP_FW_CONTENT_CERT_PK_OID;
|
||||
};
|
||||
};
|
||||
|
||||
scp_fw_content_cert: scp_fw_content_cert {
|
||||
image-id = <SCP_FW_CONTENT_CERT_ID>;
|
||||
parent = <&scp_fw_key_cert>;
|
||||
signing-key = <&scp_fw_content_pk>;
|
||||
antirollback-counter = <&trusted_nv_counter>;
|
||||
|
||||
scp_fw_hash: scp_fw_hash {
|
||||
oid = SCP_FW_HASH_OID;
|
||||
};
|
||||
};
|
||||
|
||||
soc_fw_key_cert: soc_fw_key_cert {
|
||||
image-id = <SOC_FW_KEY_CERT_ID>;
|
||||
parent = <&trusted_key_cert>;
|
||||
signing-key = <&trusted_world_pk>;
|
||||
antirollback-counter = <&trusted_nv_counter>;
|
||||
soc_fw_content_pk: soc_fw_content_pk {
|
||||
oid = SOC_FW_CONTENT_CERT_PK_OID;
|
||||
};
|
||||
};
|
||||
|
||||
soc_fw_content_cert: soc_fw_content_cert {
|
||||
image-id = <SOC_FW_CONTENT_CERT_ID>;
|
||||
parent = <&soc_fw_key_cert>;
|
||||
signing-key = <&soc_fw_content_pk>;
|
||||
antirollback-counter = <&trusted_nv_counter>;
|
||||
|
||||
soc_fw_hash: soc_fw_hash {
|
||||
oid = SOC_AP_FW_HASH_OID;
|
||||
};
|
||||
soc_fw_config_hash: soc_fw_config_hash {
|
||||
oid = SOC_FW_CONFIG_HASH_OID;
|
||||
};
|
||||
};
|
||||
|
||||
trusted_os_fw_key_cert: trusted_os_fw_key_cert {
|
||||
image-id = <TRUSTED_OS_FW_KEY_CERT_ID>;
|
||||
parent = <&trusted_key_cert>;
|
||||
signing-key = <&trusted_world_pk>;
|
||||
antirollback-counter = <&trusted_nv_counter>;
|
||||
|
||||
tos_fw_content_pk: tos_fw_content_pk {
|
||||
oid = TRUSTED_OS_FW_CONTENT_CERT_PK_OID;
|
||||
};
|
||||
};
|
||||
|
||||
trusted_os_fw_content_cert: trusted_os_fw_content_cert {
|
||||
image-id = <TRUSTED_OS_FW_CONTENT_CERT_ID>;
|
||||
parent = <&trusted_os_fw_key_cert>;
|
||||
signing-key = <&tos_fw_content_pk>;
|
||||
antirollback-counter = <&trusted_nv_counter>;
|
||||
|
||||
tos_fw_hash: tos_fw_hash {
|
||||
oid = TRUSTED_OS_FW_HASH_OID;
|
||||
};
|
||||
tos_fw_extra1_hash: tos_fw_extra1_hash {
|
||||
oid = TRUSTED_OS_FW_EXTRA1_HASH_OID;
|
||||
};
|
||||
tos_fw_extra2_hash: tos_fw_extra2_hash {
|
||||
oid = TRUSTED_OS_FW_EXTRA2_HASH_OID;
|
||||
};
|
||||
tos_fw_config_hash: tos_fw_config_hash {
|
||||
oid = TRUSTED_OS_FW_CONFIG_HASH_OID;
|
||||
};
|
||||
};
|
||||
|
||||
non_trusted_fw_content_cert: non_trusted_fw_content_cert {
|
||||
root-certificate;
|
||||
image-id = <NON_TRUSTED_FW_CONTENT_CERT_ID>;
|
||||
signing-key = <&prot_pk>;
|
||||
antirollback-counter = <&non_trusted_nv_counter>;
|
||||
|
||||
nt_world_bl_hash: nt_world_bl_hash {
|
||||
oid = NON_TRUSTED_WORLD_BOOTLOADER_HASH_OID;
|
||||
};
|
||||
nt_fw_config_hash: nt_fw_config_hash {
|
||||
oid = NON_TRUSTED_FW_CONFIG_HASH_OID;
|
||||
};
|
||||
};
|
||||
|
||||
#if defined(SPD_spmd)
|
||||
sip_sp_content_cert: sip_sp_content_cert {
|
||||
image-id = <SIP_SP_CONTENT_CERT_ID>;
|
||||
parent = <&trusted_key_cert>;
|
||||
signing-key = <&trusted_world_pk>;
|
||||
antirollback-counter = <&trusted_nv_counter>;
|
||||
|
||||
sp_pkg1_hash: sp_pkg1_hash {
|
||||
oid = SP_PKG1_HASH_OID;
|
||||
};
|
||||
sp_pkg2_hash: sp_pkg2_hash {
|
||||
oid = SP_PKG2_HASH_OID;
|
||||
};
|
||||
sp_pkg3_hash: sp_pkg3_hash {
|
||||
oid = SP_PKG3_HASH_OID;
|
||||
};
|
||||
sp_pkg4_hash: sp_pkg4_hash {
|
||||
oid = SP_PKG4_HASH_OID;
|
||||
};
|
||||
};
|
||||
|
||||
plat_sp_content_cert: plat_sp_content_cert {
|
||||
root-certificate;
|
||||
image-id = <PLAT_SP_CONTENT_CERT_ID>;
|
||||
signing-key = <&prot_pk>;
|
||||
antirollback-counter = <&non_trusted_nv_counter>;
|
||||
|
||||
sp_pkg5_hash: sp_pkg5_hash {
|
||||
oid = SP_PKG5_HASH_OID;
|
||||
};
|
||||
sp_pkg6_hash: sp_pkg6_hash {
|
||||
oid = SP_PKG6_HASH_OID;
|
||||
};
|
||||
sp_pkg7_hash: sp_pkg7_hash {
|
||||
oid = SP_PKG7_HASH_OID;
|
||||
};
|
||||
sp_pkg8_hash: sp_pkg8_hash {
|
||||
oid = SP_PKG8_HASH_OID;
|
||||
};
|
||||
};
|
||||
#endif
|
||||
};
|
||||
|
||||
images {
|
||||
compatible = "arm, img-descs";
|
||||
|
||||
hw_config {
|
||||
image-id = <HW_CONFIG_ID>;
|
||||
parent = <&trusted_boot_fw_cert>;
|
||||
hash = <&hw_config_hash>;
|
||||
};
|
||||
|
||||
scp_bl2_image {
|
||||
image-id = <SCP_BL2_IMAGE_ID>;
|
||||
parent = <&scp_fw_content_cert>;
|
||||
hash = <&scp_fw_hash>;
|
||||
};
|
||||
|
||||
bl31_image {
|
||||
image-id = <BL31_IMAGE_ID>;
|
||||
parent = <&soc_fw_content_cert>;
|
||||
hash = <&soc_fw_hash>;
|
||||
};
|
||||
|
||||
soc_fw_config {
|
||||
image-id = <SOC_FW_CONFIG_ID>;
|
||||
parent = <&soc_fw_content_cert>;
|
||||
hash = <&soc_fw_config_hash>;
|
||||
};
|
||||
|
||||
bl32_image {
|
||||
image-id = <BL32_IMAGE_ID>;
|
||||
parent = <&trusted_os_fw_content_cert>;
|
||||
hash = <&tos_fw_hash>;
|
||||
};
|
||||
|
||||
bl32_extra1_image {
|
||||
image-id = <BL32_EXTRA1_IMAGE_ID>;
|
||||
parent = <&trusted_os_fw_content_cert>;
|
||||
hash = <&tos_fw_extra1_hash>;
|
||||
};
|
||||
|
||||
bl32_extra2_image {
|
||||
image-id = <BL32_EXTRA2_IMAGE_ID>;
|
||||
parent = <&trusted_os_fw_content_cert>;
|
||||
hash = <&tos_fw_extra2_hash>;
|
||||
};
|
||||
|
||||
tos_fw_config {
|
||||
image-id = <TOS_FW_CONFIG_ID>;
|
||||
parent = <&trusted_os_fw_content_cert>;
|
||||
hash = <&tos_fw_config_hash>;
|
||||
};
|
||||
|
||||
bl33_image {
|
||||
image-id = <BL33_IMAGE_ID>;
|
||||
parent = <&non_trusted_fw_content_cert>;
|
||||
hash = <&nt_world_bl_hash>;
|
||||
};
|
||||
|
||||
nt_fw_config {
|
||||
image-id = <NT_FW_CONFIG_ID>;
|
||||
parent = <&non_trusted_fw_content_cert>;
|
||||
hash = <&nt_fw_config_hash>;
|
||||
};
|
||||
|
||||
#if defined(SPD_spmd)
|
||||
sp_pkg1 {
|
||||
image-id = <SP_PKG1_ID>;
|
||||
parent = <&sip_sp_content_cert>;
|
||||
hash = <&sp_pkg1_hash>;
|
||||
};
|
||||
|
||||
sp_pkg2 {
|
||||
image-id = <SP_PKG2_ID>;
|
||||
parent = <&sip_sp_content_cert>;
|
||||
hash = <&sp_pkg2_hash>;
|
||||
};
|
||||
|
||||
sp_pkg3 {
|
||||
image-id = <SP_PKG3_ID>;
|
||||
parent = <&sip_sp_content_cert>;
|
||||
hash = <&sp_pkg3_hash>;
|
||||
};
|
||||
|
||||
sp_pkg4 {
|
||||
image-id = <SP_PKG4_ID>;
|
||||
parent = <&sip_sp_content_cert>;
|
||||
hash = <&sp_pkg4_hash>;
|
||||
};
|
||||
|
||||
sp_pkg5 {
|
||||
image-id = <SP_PKG5_ID>;
|
||||
parent = <&plat_sp_content_cert>;
|
||||
hash = <&sp_pkg5_hash>;
|
||||
};
|
||||
|
||||
sp_pkg6 {
|
||||
image-id = <SP_PKG6_ID>;
|
||||
parent = <&plat_sp_content_cert>;
|
||||
hash = <&sp_pkg6_hash>;
|
||||
};
|
||||
|
||||
sp_pkg7 {
|
||||
image-id = <SP_PKG7_ID>;
|
||||
parent = <&plat_sp_content_cert>;
|
||||
hash = <&sp_pkg7_hash>;
|
||||
};
|
||||
|
||||
sp_pkg8 {
|
||||
image-id = <SP_PKG8_ID>;
|
||||
parent = <&plat_sp_content_cert>;
|
||||
hash = <&sp_pkg8_hash>;
|
||||
};
|
||||
#endif
|
||||
};
|
||||
};
|
||||
|
||||
non_volatile_counters: non_volatile_counters {
|
||||
compatible = "arm, non-volatile-counter";
|
||||
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
trusted_nv_counter: trusted_nv_counter {
|
||||
id = <TRUSTED_NV_CTR_ID>;
|
||||
oid = TRUSTED_FW_NVCOUNTER_OID;
|
||||
};
|
||||
|
||||
non_trusted_nv_counter: non_trusted_nv_counter {
|
||||
id = <NON_TRUSTED_NV_CTR_ID>;
|
||||
oid = NON_TRUSTED_FW_NVCOUNTER_OID;
|
||||
};
|
||||
};
|
||||
|
||||
rot_keys {
|
||||
prot_pk: prot_pk {
|
||||
oid = PROT_PK_OID;
|
||||
};
|
||||
};
|
16
plat/arm/board/fvp/fdts/fvp_cot_desc.dtsi
Normal file
16
plat/arm/board/fvp/fdts/fvp_cot_desc.dtsi
Normal file
|
@ -0,0 +1,16 @@
|
|||
/*
|
||||
* Copyright (c) 2024, Arm Limited. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
||||
|
||||
#if COT_DESC_IN_DTB
|
||||
#if defined(ARM_COT_cca)
|
||||
#include "cca_cot_descriptors.dtsi"
|
||||
#elif defined(ARM_COT_dualroot)
|
||||
#include "dualroot_cot_descriptors.dtsi"
|
||||
#elif defined(ARM_COT_tbbr)
|
||||
#include "tbbr_cot_descriptors.dtsi"
|
||||
#endif
|
||||
#endif
|
|
@ -103,13 +103,7 @@
|
|||
#endif /* ARM_BL2_SP_LIST_DTS */
|
||||
};
|
||||
|
||||
#if COT_DESC_IN_DTB
|
||||
#if defined(ARM_COT_cca)
|
||||
#include "cca_cot_descriptors.dtsi"
|
||||
#elif defined(ARM_COT_tbbr)
|
||||
#include "tbbr_cot_descriptors.dtsi"
|
||||
#endif
|
||||
#endif
|
||||
#include "fvp_cot_desc.dtsi"
|
||||
|
||||
#if MEASURED_BOOT
|
||||
#include "event_log.dtsi"
|
||||
|
|
|
@ -385,7 +385,12 @@ ifneq (${TRUSTED_BOARD_BOOT},0)
|
|||
endif
|
||||
endif
|
||||
else ifeq (${COT},dualroot)
|
||||
AUTH_SOURCES += drivers/auth/dualroot/cot.c
|
||||
BL1_SOURCES += drivers/auth/dualroot/cot.c
|
||||
ifneq (${COT_DESC_IN_DTB},0)
|
||||
BL2_SOURCES += lib/fconf/fconf_cot_getter.c
|
||||
else
|
||||
BL2_SOURCES += drivers/auth/dualroot/cot.c
|
||||
endif
|
||||
else ifeq (${COT},cca)
|
||||
BL1_SOURCES += drivers/auth/cca/cot.c
|
||||
ifneq (${COT_DESC_IN_DTB},0)
|
||||
|
|
Loading…
Add table
Reference in a new issue