aboutsummaryrefslogtreecommitdiff
path: root/common/desc_image_load.c
diff options
context:
space:
mode:
authorAchin Gupta <achin.gupta@arm.com>2019-10-11 14:54:48 +0100
committerMax Shvetsov <maksims.svecovs@arm.com>2020-02-10 14:09:10 +0000
commit0cb64d01d934cf9b8368a8afea839c7a9bd9a701 (patch)
tree495287b653d85c3515028e4a06f7901564b101f3 /common/desc_image_load.c
parentd8b225a1a6d3d4bf7bf51fbd731413f76f6b8073 (diff)
downloadtrusted-firmware-a-0cb64d01d934cf9b8368a8afea839c7a9bd9a701.tar.gz
SPMD: add support for an example SPM core manifest
This patch repurposes the TOS FW configuration file as the manifest for the SPM core component which will reside at the secure EL adjacent to EL3. The SPM dispatcher component will use the manifest to determine how the core component must be initialised. Routines and data structure to parse the manifest have also been added. Signed-off-by: Achin Gupta <achin.gupta@arm.com> Signed-off-by: Artsem Artsemenka <artsem.artsemenka@arm.com> Change-Id: Id94f8ece43b4e05609f0a1d364708a912f6203cb
Diffstat (limited to 'common/desc_image_load.c')
-rw-r--r--common/desc_image_load.c18
1 files changed, 15 insertions, 3 deletions
diff --git a/common/desc_image_load.c b/common/desc_image_load.c
index f2e8f60546..c8dd403ff5 100644
--- a/common/desc_image_load.c
+++ b/common/desc_image_load.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016-2019, ARM Limited and Contributors. All rights reserved.
+ * Copyright (c) 2016-2020, ARM Limited and Contributors. All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
@@ -215,6 +215,9 @@ void populate_next_bl_params_config(bl_params_t *bl2_to_next_bl_params)
bl_params_node_t *params_node;
unsigned int fw_config_id;
uintptr_t hw_config_base = 0, fw_config_base;
+#if defined(SPD_spmd)
+ uint32_t fw_config_size = 0;
+#endif
bl_mem_params_node_t *mem_params;
assert(bl2_to_next_bl_params != NULL);
@@ -249,10 +252,14 @@ void populate_next_bl_params_config(bl_params_t *bl2_to_next_bl_params)
if (fw_config_id != INVALID_IMAGE_ID) {
mem_params = get_bl_mem_params_node(fw_config_id);
- if (mem_params != NULL)
+ if (mem_params != NULL) {
fw_config_base = mem_params->image_info.image_base;
+#if defined(SPD_spmd)
+ fw_config_size =
+ mem_params->image_info.image_size;
+#endif
+ }
}
-
/*
* Pass hw and tb_fw config addresses to next images. NOTE - for
* EL3 runtime images (BL31 for AArch64 and BL32 for AArch32),
@@ -273,6 +280,11 @@ void populate_next_bl_params_config(bl_params_t *bl2_to_next_bl_params)
if (params_node->ep_info->args.arg1 == 0U)
params_node->ep_info->args.arg1 =
hw_config_base;
+#if defined(SPD_spmd)
+ if (params_node->ep_info->args.arg2 == 0U)
+ params_node->ep_info->args.arg2 =
+ fw_config_size;
+#endif
}
}
}