diff --git a/plat/juno/bl2_plat_setup.c b/plat/juno/bl2_plat_setup.c index 563f05b..5be725a 100644 --- a/plat/juno/bl2_plat_setup.c +++ b/plat/juno/bl2_plat_setup.c @@ -142,6 +142,10 @@ ******************************************************************************/ struct entry_point_info *bl2_plat_get_bl31_ep_info(void) { +#if DEBUG + bl31_params_mem.bl31_ep_info.args.arg1 = JUNO_BL31_PLAT_PARAM_VAL; +#endif + return &bl31_params_mem.bl31_ep_info; } diff --git a/plat/juno/bl31_plat_setup.c b/plat/juno/bl31_plat_setup.c index cb5fd1e..2eac0fb 100644 --- a/plat/juno/bl31_plat_setup.c +++ b/plat/juno/bl31_plat_setup.c @@ -111,12 +111,17 @@ /* * Check params passed from BL2 should not be NULL, - * We are not checking plat_params_from_bl2 as NULL as we are not - * using it on Juno */ assert(from_bl2 != NULL); assert(from_bl2->h.type == PARAM_BL31); assert(from_bl2->h.version >= VERSION_1); + /* + * In debug builds, we pass a special value in 'plat_params_from_bl2' + * to verify platform parameters from BL2 to BL3-1. + * In release builds, it's not used. + */ + assert(((unsigned long long)plat_params_from_bl2) == + JUNO_BL31_PLAT_PARAM_VAL); /* * Copy BL3-2 and BL3-3 entry point information. diff --git a/plat/juno/juno_def.h b/plat/juno/juno_def.h index da852c5..6b3ba57 100644 --- a/plat/juno/juno_def.h +++ b/plat/juno/juno_def.h @@ -31,6 +31,9 @@ #ifndef __JUNO_DEF_H__ #define __JUNO_DEF_H__ +/* Special value used to verify platform parameters from BL2 to BL3-1 */ +#define JUNO_BL31_PLAT_PARAM_VAL 0x0f1e2d3c4b5a6978ULL + /******************************************************************************* * Juno memory map related constants ******************************************************************************/