aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBalint Dobszay <balint.dobszay@arm.com>2021-03-29 18:47:50 +0200
committerBalint Dobszay <balint.dobszay@arm.com>2021-04-13 18:52:10 +0200
commit35c6d643b5f0c0387702e22bf742dd4878ca5ddd (patch)
tree8bcebacc781994ce792595ce51a422b43c7963dc
parent0fdceeabdc4d29317dbcd2607ea2b5e78179e1f5 (diff)
downloadtrusted-services-35c6d643b5f0c0387702e22bf742dd4878ca5ddd.tar.gz
Create and export SP layout JSON
Configure a JSON file for each SP and export it to the install dir. The individual files should be merged by the integrator to form the SP_LAYOUT_FILE JSON used by TF-A to create the SP packages. Signed-off-by: Balint Dobszay <balint.dobszay@arm.com> Change-Id: I63674e8e584dd3285490f3be51c228718f39a998
-rw-r--r--environments/opteesp/ExportSp.cmake4
-rw-r--r--environments/opteesp/sp.mk.in4
-rw-r--r--environments/opteesp/sp_pkg.json.in6
3 files changed, 14 insertions, 0 deletions
diff --git a/environments/opteesp/ExportSp.cmake b/environments/opteesp/ExportSp.cmake
index 23e03ac98..c8d74fab4 100644
--- a/environments/opteesp/ExportSp.cmake
+++ b/environments/opteesp/ExportSp.cmake
@@ -34,6 +34,10 @@ 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)
+configure_file(${CMAKE_CURRENT_LIST_DIR}/sp_pkg.json.in
+ ${CMAKE_CURRENT_BINARY_DIR}/${EXPORT_SP_NAME}.json @ONLY NEWLINE_STYLE UNIX)
+install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${EXPORT_SP_NAME}.json DESTINATION ${TS_ENV}/json)
+
unset(DTS_TAG)
unset(DTS_NODE)
unset(PARENT_LIST_DIR)
diff --git a/environments/opteesp/sp.mk.in b/environments/opteesp/sp.mk.in
index c0439f8a9..c44ad59eb 100644
--- a/environments/opteesp/sp.mk.in
+++ b/environments/opteesp/sp.mk.in
@@ -13,5 +13,9 @@ ifeq (,${@EXPORT_SP_UUID@-included})
@EXPORT_SP_UUID@-included=y
endif
+ifeq (embedded,${SP_PACKAGING_METHOD})
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\""
+else ifeq (fip,${SP_PACKAGING_METHOD})
+TS_SP_JSON_LIST+=${TS_INSTALL_PREFIX}/opteesp/json/@EXPORT_SP_NAME@.json
+endif
diff --git a/environments/opteesp/sp_pkg.json.in b/environments/opteesp/sp_pkg.json.in
new file mode 100644
index 000000000..c7bfb4c6d
--- /dev/null
+++ b/environments/opteesp/sp_pkg.json.in
@@ -0,0 +1,6 @@
+{
+ "@EXPORT_SP_NAME@": {
+ "image": "../bin/@EXPORT_SP_UUID@.stripped.elf",
+ "pm": "../manifest/@EXPORT_SP_UUID@.dts"
+ }
+} \ No newline at end of file