mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-11 07:04:22 +00:00
refactor(arm): simplify early platform setup functions
Refactor `arm_sp_min_early_platform_setup` to accept generic `u_register_r` values to support receiving firmware handoff boot arguments in common code. This has the added benefit of simplifying the interface into common early platform setup. Change-Id: Idfc3d41f94f2bf3a3a0c7ca39f6b9b0013836e3a Signed-off-by: Harrison Mutai <harrison.mutai@arm.com>
This commit is contained in:
parent
3fabca724a
commit
8921349894
6 changed files with 15 additions and 15 deletions
|
@ -298,8 +298,8 @@ void arm_transfer_list_get_heap_info(void **heap_addr, size_t *heap_size);
|
|||
void arm_tsp_early_platform_setup(void);
|
||||
|
||||
/* SP_MIN utility functions */
|
||||
void arm_sp_min_early_platform_setup(void *from_bl2, uintptr_t tos_fw_config,
|
||||
uintptr_t hw_config, void *plat_params_from_bl2);
|
||||
void arm_sp_min_early_platform_setup(u_register_t arg0, u_register_t arg1,
|
||||
u_register_t arg2, u_register_t arg3);
|
||||
void arm_sp_min_plat_runtime_setup(void);
|
||||
void arm_sp_min_plat_arch_setup(void);
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2019, ARM Limited. All rights reserved.
|
||||
* Copyright (c) 2019-2025, Arm Limited. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
@ -11,7 +11,7 @@
|
|||
void plat_arm_sp_min_early_platform_setup(u_register_t arg0, u_register_t arg1,
|
||||
u_register_t arg2, u_register_t arg3)
|
||||
{
|
||||
arm_sp_min_early_platform_setup((void *)arg0, arg1, arg2, (void *)arg3);
|
||||
arm_sp_min_early_platform_setup(arg0, arg1, arg2, arg3);
|
||||
|
||||
/* enable snoop control unit */
|
||||
enable_snoop_ctrl_unit(A5DS_SCU_BASE);
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2019, Arm Limited and Contributors. All rights reserved.
|
||||
* Copyright (c) 2019-2025, Arm Limited and Contributors. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
@ -9,5 +9,5 @@
|
|||
void plat_arm_sp_min_early_platform_setup(u_register_t arg0, u_register_t arg1,
|
||||
u_register_t arg2, u_register_t arg3)
|
||||
{
|
||||
arm_sp_min_early_platform_setup((void *)arg0, arg1, arg2, (void *)arg3);
|
||||
arm_sp_min_early_platform_setup(arg0, arg1, arg2, arg3);
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2016-2023, Arm Limited and Contributors. All rights reserved.
|
||||
* Copyright (c) 2016-2025, Arm Limited and Contributors. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
@ -34,7 +34,7 @@ void plat_arm_sp_min_early_platform_setup(u_register_t arg0, u_register_t arg1,
|
|||
}
|
||||
#endif /* !RESET_TO_SP_MIN && !RESET_TO_BL2 */
|
||||
|
||||
arm_sp_min_early_platform_setup((void *)arg0, arg1, arg2, (void *)arg3);
|
||||
arm_sp_min_early_platform_setup(arg0, arg1, arg2, arg3);
|
||||
|
||||
/* Initialize the platform config for future decision making */
|
||||
fvp_config_setup();
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2019, Arm Limited. All rights reserved.
|
||||
* Copyright (c) 2019-2025, Arm Limited. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
@ -11,5 +11,5 @@
|
|||
void plat_arm_sp_min_early_platform_setup(u_register_t arg0, u_register_t arg1,
|
||||
u_register_t arg2, u_register_t arg3)
|
||||
{
|
||||
arm_sp_min_early_platform_setup((void *)arg0, arg1, arg2, (void *)arg3);
|
||||
arm_sp_min_early_platform_setup(arg0, arg1, arg2, arg3);
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2016-2024, ARM Limited and Contributors. All rights reserved.
|
||||
* Copyright (c) 2016-2025, Arm Limited and Contributors. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
@ -61,8 +61,8 @@ entry_point_info_t *sp_min_plat_get_bl33_ep_info(void)
|
|||
/*******************************************************************************
|
||||
* Utility function to perform early platform setup.
|
||||
******************************************************************************/
|
||||
void arm_sp_min_early_platform_setup(void *from_bl2, uintptr_t tos_fw_config,
|
||||
uintptr_t hw_config, void *plat_params_from_bl2)
|
||||
void arm_sp_min_early_platform_setup(u_register_t arg0, u_register_t arg1,
|
||||
u_register_t arg2, u_register_t arg3)
|
||||
{
|
||||
/* Initialize the console to provide early debug support */
|
||||
arm_console_boot_init();
|
||||
|
@ -99,7 +99,7 @@ void arm_sp_min_early_platform_setup(void *from_bl2, uintptr_t tos_fw_config,
|
|||
/*
|
||||
* Check params passed from BL2 should not be NULL,
|
||||
*/
|
||||
bl_params_t *params_from_bl2 = (bl_params_t *)from_bl2;
|
||||
bl_params_t *params_from_bl2 = (bl_params_t *)arg0;
|
||||
assert(params_from_bl2 != NULL);
|
||||
assert(params_from_bl2->h.type == PARAM_BL_PARAMS);
|
||||
assert(params_from_bl2->h.version >= VERSION_2);
|
||||
|
@ -132,7 +132,7 @@ void arm_sp_min_early_platform_setup(void *from_bl2, uintptr_t tos_fw_config,
|
|||
void plat_arm_sp_min_early_platform_setup(u_register_t arg0, u_register_t arg1,
|
||||
u_register_t arg2, u_register_t arg3)
|
||||
{
|
||||
arm_sp_min_early_platform_setup((void *)arg0, arg1, arg2, (void *)arg3);
|
||||
arm_sp_min_early_platform_setup(arg0, arg1, arg2, arg3);
|
||||
|
||||
/*
|
||||
* Initialize Interconnect for this cluster during cold boot.
|
||||
|
|
Loading…
Add table
Reference in a new issue