mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-08-16 09:27:01 +02:00
The bl2_early_platform_setup() and bl2_platform_setup() were redefined for Juno AArch32 eventhough CSS platform layer had same definition for them. The CSS definitions definitions were previously restricted to EL3_PAYLOAD_BASE builds and this is now modified to include the Juno AArch32 builds as well thus allowing us to remove the duplicate definitions in Juno platform layer. Change-Id: Ibd1d8c1428cc1d51ac0ba90f19f5208ff3278ab5 Signed-off-by: Soby Mathew <soby.mathew@arm.com>
33 lines
1.1 KiB
C
33 lines
1.1 KiB
C
/*
|
|
* Copyright (c) 2016-2017, ARM Limited and Contributors. All rights reserved.
|
|
*
|
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
*/
|
|
|
|
#include <assert.h>
|
|
#include <bl_common.h>
|
|
#include <desc_image_load.h>
|
|
#include <plat_arm.h>
|
|
|
|
#if JUNO_AARCH32_EL3_RUNTIME
|
|
/*******************************************************************************
|
|
* This function changes the spsr for BL32 image to bypass
|
|
* the check in BL1 AArch64 exception handler. This is needed in the aarch32
|
|
* boot flow as the core comes up in aarch64 and to enter the BL32 image a warm
|
|
* reset in aarch32 state is required.
|
|
******************************************************************************/
|
|
int bl2_plat_handle_post_image_load(unsigned int image_id)
|
|
{
|
|
int err = arm_bl2_handle_post_image_load(image_id);
|
|
|
|
if (!err && (image_id == BL32_IMAGE_ID)) {
|
|
bl_mem_params_node_t *bl_mem_params = get_bl_mem_params_node(image_id);
|
|
assert(bl_mem_params);
|
|
bl_mem_params->ep_info.spsr = SPSR_64(MODE_EL3, MODE_SP_ELX,
|
|
DISABLE_ALL_EXCEPTIONS);
|
|
}
|
|
|
|
return err;
|
|
}
|
|
#endif /* JUNO_AARCH32_EL3_RUNTIME */
|