diff options
author | Andrew Davis | 2022-10-20 12:12:19 -0500 |
---|---|---|
committer | Tom Rini | 2022-12-12 14:03:11 -0500 |
commit | 1eaffe39583a784390d579c3ca9e06b58164f4d0 (patch) | |
tree | 97c3cb3abe0735a0fe7b74acc2d738cb305c7bd2 /arch | |
parent | bc71afc3c5399c062c724f01d6ff83af72e14a42 (diff) |
arm: mach-omap2: Move common image process functions out of board files
The functions board_fit_image_post_process() and board_tee_image_process()
are not actually board specific (despite their names). Any board using the
OMAP2 family can use these functions. Move them to boot-common.c.
Signed-off-by: Andrew Davis <afd@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/mach-omap2/boot-common.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/boot-common.c b/arch/arm/mach-omap2/boot-common.c index c463c96c74c..f955d494718 100644 --- a/arch/arm/mach-omap2/boot-common.c +++ b/arch/arm/mach-omap2/boot-common.c @@ -15,6 +15,7 @@ #include <spl.h> #include <asm/global_data.h> #include <asm/omap_common.h> +#include <asm/omap_sec_common.h> #include <asm/arch/omap.h> #include <asm/arch/mmc_host_def.h> #include <asm/arch/sys_proto.h> @@ -22,6 +23,7 @@ #include <scsi.h> #include <i2c.h> #include <remoteproc.h> +#include <image.h> DECLARE_GLOBAL_DATA_PTR; @@ -331,3 +333,17 @@ void arch_preboot_os(void) ahci_reset((void __iomem *)DWC_AHSATA_BASE); } #endif + +#ifdef CONFIG_TI_SECURE_DEVICE +void board_fit_image_post_process(const void *fit, int node, void **p_image, + size_t *p_size) +{ + secure_boot_verify_image(p_image, p_size); +} + +static void tee_image_process(ulong tee_image, size_t tee_size) +{ + secure_tee_install((u32)tee_image); +} +U_BOOT_FIT_LOADABLE_HANDLER(IH_TYPE_TEE, tee_image_process); +#endif |