plat/arm: Save BL2 descriptors to reserved memory.
On ARM platforms, the BL2 memory can be overlaid by BL31/BL32. The memory
descriptors describing the list of executable images are created in BL2
R/W memory, which could be possibly corrupted later on by BL31/BL32 due
to overlay. This patch creates a reserved location in SRAM for these
descriptors and are copied over by BL2 before handing over to next BL
image.
Also this patch increases the PLAT_ARM_MAX_BL2_SIZE for juno when TBBR
is enabled.
Fixes ARM-Software/tf-issues#626
Change-Id: I755735706fa702024b4032f51ed4895b3687377f
Signed-off-by: Sathees Balya <sathees.balya@arm.com>
diff --git a/plat/arm/css/sgi/sgi_image_load.c b/plat/arm/css/sgi/sgi_image_load.c
index 1ed219d..e52124f 100644
--- a/plat/arm/css/sgi/sgi_image_load.c
+++ b/plat/arm/css/sgi/sgi_image_load.c
@@ -11,6 +11,7 @@
#include <common/desc_image_load.h>
#include <plat/common/platform.h>
+#include <plat_arm.h>
#include <sgi_variant.h>
/*******************************************************************************
@@ -72,14 +73,11 @@
bl_params_t *plat_get_next_bl_params(void)
{
int ret;
- bl_params_t *next_bl_params;
ret = plat_sgi_append_config_node();
if (ret != 0)
panic();
- next_bl_params = get_next_bl_params_from_mem_params_desc();
- populate_next_bl_params_config(next_bl_params);
-
- return next_bl_params;
+ return arm_get_next_bl_params();
}
+