Skip to content
Snippets Groups Projects
Commit 60e20e78 authored by Frieder Schrempf's avatar Frieder Schrempf
Browse files

WIP: imx: hab: Make HAB support build for i.MX8MM


This is only a quick and compile-tested patch for making HAB build
on i.MX8MM.

There is still a load of warnings reported in arch/arm/mach-imx/hab.c.
It looks like this driver still needs work to get ready for ARM64.

Signed-off-by: default avatarFrieder Schrempf <frieder.schrempf@kontron.de>
parent 8328ecff
No related branches found
No related tags found
No related merge requests found
......@@ -275,3 +275,4 @@ void enable_ocotp_clk(unsigned char enable);
int enable_i2c_clk(unsigned char enable, unsigned int i2c_num);
int set_clk_enet(enum enet_freq type);
int set_clk_eqos(enum enet_freq type);
void hab_caam_clock_enable(unsigned char enable);
......@@ -47,9 +47,11 @@ ifneq ($(CONFIG_SPL_BUILD),y)
obj-$(CONFIG_IMX_BOOTAUX) += imx_bootaux.o
endif
obj-$(CONFIG_SATA) += sata.o
obj-$(CONFIG_IMX_HAB) += hab.o
obj-$(CONFIG_SYSCOUNTER_TIMER) += syscounter.o
endif
ifeq ($(SOC),$(filter $(SOC),mx6 mx7 imx8m))
obj-$(CONFIG_IMX_HAB) += hab.o
endif
ifeq ($(SOC),$(filter $(SOC),mx7ulp))
obj-y += cache.o mmdc_size.o
obj-$(CONFIG_IMX_HAB) += hab.o
......
......@@ -660,6 +660,7 @@ int imx_hab_authenticate_image(uint32_t ddr_start, uint32_t image_size,
* crash.
*/
/* Check MMU enabled */
#if defined(CONFIG_MX6)
if (is_soc_type(MXC_SOC_MX6) && get_cr() & CR_M) {
if (is_mx6dq()) {
/*
......@@ -676,6 +677,7 @@ int imx_hab_authenticate_image(uint32_t ddr_start, uint32_t image_size,
writel(1, MX6SL_PU_IROM_MMU_EN_VAR);
}
}
#endif
load_addr = (uint32_t)hab_rvt_authenticate_image(
HAB_CID_UBOOT,
......
......@@ -928,3 +928,14 @@ int set_clk_enet(enum enet_freq type)
return 0;
}
#endif
#ifdef CONFIG_IMX_HAB
void hab_caam_clock_enable(unsigned char enable)
{
/*
* According to the RM there is no separate clock gate
* for the CAAM clock on i.MX8MM.
*/
return;
}
#endif
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment