diff options
-rw-r--r-- | deployments/crypto/opteesp/default_crypto.dts.in | 19 | ||||
-rw-r--r-- | deployments/secure-storage/opteesp/default_secure-storage.dts.in | 19 | ||||
-rw-r--r-- | environments/opteesp/ExportSp.cmake | 22 | ||||
-rw-r--r-- | environments/opteesp/sp.mk.in | 1 |
4 files changed, 61 insertions, 0 deletions
diff --git a/deployments/crypto/opteesp/default_crypto.dts.in b/deployments/crypto/opteesp/default_crypto.dts.in new file mode 100644 index 000000000..92b709b8b --- /dev/null +++ b/deployments/crypto/opteesp/default_crypto.dts.in @@ -0,0 +1,19 @@ +/* + * Copyright (c) 2021, Arm Limited and Contributors. All rights reserved. + * + * SPDX-License-Identifier: BSD-3-Clause + */ + +@DTS_TAG@ + +@DTS_NODE@ { + compatible = "arm,ffa-manifest-1.0"; + ffa-version = <0x00010000>; /* 31:16 - Major, 15:0 - Minor */ + uuid = <@EXPORT_SP_UUID_DT@>; + description = "Crypto"; + execution-ctx-count = <1>; + exception-level = <1>; /* S-EL0 */ + execution-state = <0>; /* AArch64 */ + xlat-granule = <0>; /* 4KiB */ + messaging-method = <0>; /* Direct messaging only */ +}; diff --git a/deployments/secure-storage/opteesp/default_secure-storage.dts.in b/deployments/secure-storage/opteesp/default_secure-storage.dts.in new file mode 100644 index 000000000..1a8d6a327 --- /dev/null +++ b/deployments/secure-storage/opteesp/default_secure-storage.dts.in @@ -0,0 +1,19 @@ +/* + * Copyright (c) 2021, Arm Limited and Contributors. All rights reserved. + * + * SPDX-License-Identifier: BSD-3-Clause + */ + +@DTS_TAG@ + +@DTS_NODE@ { + compatible = "arm,ffa-manifest-1.0"; + ffa-version = <0x00010000>; /* 31:16 - Major, 15:0 - Minor */ + uuid = <@EXPORT_SP_UUID_DT@>; + description = "Secure Storage"; + execution-ctx-count = <1>; + exception-level = <1>; /* S-EL0 */ + execution-state = <0>; /* AArch64 */ + xlat-granule = <0>; /* 4KiB */ + messaging-method = <0>; /* Direct messaging only */ +}; diff --git a/environments/opteesp/ExportSp.cmake b/environments/opteesp/ExportSp.cmake index b71a65786..23e03ac98 100644 --- a/environments/opteesp/ExportSp.cmake +++ b/environments/opteesp/ExportSp.cmake @@ -16,5 +16,27 @@ endforeach() configure_file(${CMAKE_CURRENT_LIST_DIR}/sp.mk.in ${CMAKE_CURRENT_BINARY_DIR}/${EXPORT_SP_NAME}.mk @ONLY NEWLINE_STYLE UNIX) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${EXPORT_SP_NAME}.mk DESTINATION ${TS_ENV}/lib/make) +get_filename_component(PARENT_LIST_DIR ${CMAKE_PARENT_LIST_FILE} DIRECTORY) +string(REGEX REPLACE + "([a-f0-9]+)-([a-f0-9]+)-([a-f0-9]+)-([a-f0-9]+)-([a-f0-9][a-f0-9][a-f0-9][a-f0-9])([a-f0-9]+)" + "0x\\1 0x\\2\\3 0x\\4\\5 0x\\6" + EXPORT_SP_UUID_DT ${EXPORT_SP_UUID}) + +set(DTS_TAG "") +set(DTS_NODE "${EXPORT_SP_NAME}") +configure_file(${PARENT_LIST_DIR}/default_${EXPORT_SP_NAME}.dts.in + ${CMAKE_CURRENT_BINARY_DIR}/${EXPORT_SP_UUID}.dtsi @ONLY NEWLINE_STYLE UNIX) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${EXPORT_SP_UUID}.dtsi DESTINATION ${TS_ENV}/manifest) + +set(DTS_TAG "/dts-v1/;") +set(DTS_NODE "/") +configure_file(${PARENT_LIST_DIR}/default_${EXPORT_SP_NAME}.dts.in + ${CMAKE_CURRENT_BINARY_DIR}/${EXPORT_SP_UUID}.dts @ONLY NEWLINE_STYLE UNIX) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${EXPORT_SP_UUID}.dts DESTINATION ${TS_ENV}/manifest) + +unset(DTS_TAG) +unset(DTS_NODE) +unset(PARENT_LIST_DIR) +unset(EXPORT_SP_UUID_DT) unset(EXPORT_SP_NAME) unset(EXPORT_SP_UUID) diff --git a/environments/opteesp/sp.mk.in b/environments/opteesp/sp.mk.in index d29baebdb..c0439f8a9 100644 --- a/environments/opteesp/sp.mk.in +++ b/environments/opteesp/sp.mk.in @@ -14,3 +14,4 @@ ifeq (,${@EXPORT_SP_UUID@-included}) endif OPTEE_OS_COMMON_EXTRA_FLAGS+=EARLY_TA_PATHS+=${TS_INSTALL_PREFIX}/opteesp/bin/@EXPORT_SP_UUID@.stripped.elf +TS_SP_DTSI_LIST+="\\n\#include \"${TS_INSTALL_PREFIX}/opteesp/manifest/@EXPORT_SP_UUID@.dtsi\"" |