mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-18 10:34:19 +00:00

In case of load error, platform may need to try another instance, either from another storage, or from the same storage in case of PSA FWU. On MTD devices such as NAND, it is required to define backup partitions. A new function plat_setup_try_img_ops() should be called by platform code to register handlers (plat_try_images_ops) to manage loading other images. Signed-off-by: Yann Gautier <yann.gautier@st.com> Signed-off-by: Lionel Debieve <lionel.debieve@foss.st.com> Change-Id: Ideaecaf296c0037a26fb4e6680f33e507111378a
28 lines
778 B
C
28 lines
778 B
C
/*
|
|
* Copyright (c) 2016-2024, ARM Limited and Contributors. All rights reserved.
|
|
*
|
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
*/
|
|
|
|
#include <lib/xlat_tables/xlat_mmu_helpers.h>
|
|
#include <plat/common/platform.h>
|
|
|
|
/* Pointer and function to register platform function to load alernate images */
|
|
const struct plat_try_images_ops *plat_try_img_ops;
|
|
|
|
void plat_setup_try_img_ops(const struct plat_try_images_ops *plat_try_ops)
|
|
{
|
|
plat_try_img_ops = plat_try_ops;
|
|
}
|
|
|
|
/*
|
|
* The following platform setup functions are weakly defined. They
|
|
* provide typical implementations that may be re-used by multiple
|
|
* platforms but may also be overridden by a platform if required.
|
|
*/
|
|
#pragma weak bl32_plat_enable_mmu
|
|
|
|
void bl32_plat_enable_mmu(uint32_t flags)
|
|
{
|
|
enable_mmu_svc_mon(flags);
|
|
}
|