diff options
author | Nitin Garg <nitin.garg@freescale.com> | 2014-05-27 08:37:44 -0500 |
---|---|---|
committer | Nitin Garg <nitin.garg@freescale.com> | 2014-05-27 08:37:44 -0500 |
commit | 0802947cfb94789cdb6b8a402a7c4523549c2a12 (patch) | |
tree | f7db7449e67346b334cc87573134dafe9d40b00b /arch/arm/include | |
parent | b3b8da14c9469551991b09e24520eeed8240bafe (diff) | |
download | u-boot-imx-0802947cfb94789cdb6b8a402a7c4523549c2a12.zip u-boot-imx-0802947cfb94789cdb6b8a402a7c4523549c2a12.tar.gz u-boot-imx-0802947cfb94789cdb6b8a402a7c4523549c2a12.tar.bz2 |
ENGR00315499-3: Support i.MX6 HAB authentication of kernel image
Support HAB authentication of kernel or secondary images via bootm
or hab_auth_img u-boot command.
Signed-off-by: Nitin Garg <nitin.garg@freescale.com>
Diffstat (limited to 'arch/arm/include')
-rw-r--r-- | arch/arm/include/asm/arch-mx6/clock.h | 4 | ||||
-rw-r--r-- | arch/arm/include/asm/arch-mx6/hab.h | 17 | ||||
-rw-r--r-- | arch/arm/include/asm/arch-mx6/imx-regs.h | 5 | ||||
-rw-r--r-- | arch/arm/include/asm/arch-mx6/sys_proto.h | 2 |
4 files changed, 22 insertions, 6 deletions
diff --git a/arch/arm/include/asm/arch-mx6/clock.h b/arch/arm/include/asm/arch-mx6/clock.h index 1b4ded7..8a706a4 100644 --- a/arch/arm/include/asm/arch-mx6/clock.h +++ b/arch/arm/include/asm/arch-mx6/clock.h @@ -59,4 +59,8 @@ int enable_pcie_clock(void); int enable_i2c_clk(unsigned char enable, unsigned i2c_num); void enable_ipu_clock(void); int enable_fec_anatop_clock(enum enet_freq freq); +#ifdef CONFIG_SECURE_BOOT +void hab_caam_clock_enable(void); +void hab_caam_clock_disable(void); +#endif #endif /* __ASM_ARCH_CLOCK_H */ diff --git a/arch/arm/include/asm/arch-mx6/hab.h b/arch/arm/include/asm/arch-mx6/hab.h index d724f20..7636c05 100644 --- a/arch/arm/include/asm/arch-mx6/hab.h +++ b/arch/arm/include/asm/arch-mx6/hab.h @@ -53,11 +53,18 @@ typedef void *hab_rvt_authenticate_image_t(uint8_t, ptrdiff_t, void **, size_t *, hab_loader_callback_f_t); typedef void hapi_clock_init_t(void); -#define HAB_RVT_REPORT_EVENT (*(uint32_t *)0x000000B4) -#define HAB_RVT_REPORT_STATUS (*(uint32_t *)0x000000B8) -#define HAB_RVT_AUTHENTICATE_IMAGE (*(uint32_t *)0x000000A4) -#define HAB_RVT_ENTRY (*(uint32_t *)0x00000098) -#define HAB_RVT_EXIT (*(uint32_t *)0x0000009C) +#define HAB_RVT_REPORT_EVENT (*(uint32_t *) 0x000000B4) +#define HAB_RVT_REPORT_STATUS (*(uint32_t *) 0x000000B8) +#define HAB_RVT_AUTHENTICATE_IMAGE (*(uint32_t *) 0x000000A4) +#define HAB_RVT_ENTRY (*(uint32_t *) 0x00000098) +#define HAB_RVT_EXIT (*(uint32_t *) 0x0000009C) + +#define HAB_RVT_REPORT_EVENT_NEW (*(uint32_t *) 0x000000B8) +#define HAB_RVT_REPORT_STATUS_NEW (*(uint32_t *) 0x000000BC) +#define HAB_RVT_AUTHENTICATE_IMAGE_NEW (*(uint32_t *) 0x000000A8) +#define HAB_RVT_ENTRY_NEW (*(uint32_t *) 0x0000009C) +#define HAB_RVT_EXIT_NEW (*(uint32_t *) 0x000000A0) + #define HAB_RVT_CLOCK_INIT ((hapi_clock_init_t *)0x0000024D) #define HAB_CID_ROM 0 /**< ROM Caller ID */ diff --git a/arch/arm/include/asm/arch-mx6/imx-regs.h b/arch/arm/include/asm/arch-mx6/imx-regs.h index f1f8f5f..8a3243d 100644 --- a/arch/arm/include/asm/arch-mx6/imx-regs.h +++ b/arch/arm/include/asm/arch-mx6/imx-regs.h @@ -217,6 +217,11 @@ #define IP2APB_USBPHY2_BASE_ADDR (AIPS2_OFF_BASE_ADDR + 0x7C000) #define CHIP_REV_1_0 0x10 +#define CHIP_REV_1_1 0x11 +#define CHIP_REV_1_2 0x12 +#define CHIP_REV_1_3 0x13 +#define CHIP_REV_1_4 0x14 +#define CHIP_REV_1_5 0x15 #define IRAM_SIZE 0x00040000 #define FEC_QUIRK_ENET_MAC diff --git a/arch/arm/include/asm/arch-mx6/sys_proto.h b/arch/arm/include/asm/arch-mx6/sys_proto.h index 38851a1..dfca85d 100644 --- a/arch/arm/include/asm/arch-mx6/sys_proto.h +++ b/arch/arm/include/asm/arch-mx6/sys_proto.h @@ -11,7 +11,7 @@ #include <asm/imx-common/regs-common.h> #include "../arch-imx/cpu.h" -#define is_soc_rev(rev) ((get_cpu_rev() & 0xFF) - rev) +#define is_soc_rev(rev) ((int)((get_cpu_rev() & 0xFF) - rev)) u32 get_cpu_rev(void); /* returns MXC_CPU_ value */ |