From 6aff5b5524184117670d7fd66fba30dd9c87f3ee Mon Sep 17 00:00:00 2001 From: "Diaz de Grenu, Jose" Date: Wed, 19 Oct 2016 17:19:58 +0200 Subject: [PATCH] trustfence: fix sign/encryption for very small artifacts The HAB on the i.MX6/i.MX6UL expects an entrypoint which is used to pass execution to U-Boot in the ROM code. In later executions of HAB, U-Boot calls the HAB but ignores this value. A fixed value of 0x1000 was being used for the entrypoint, which is too big for really small artifacts, like bootscripts. This commit reduces the value to 0x100. This allows to sign and encrypt artifacts as small as 260 bytes. Signed-off-by: Diaz de Grenu, Jose --- .../trustfence/trustfence-sign-tools/trustfence-sign-kernel.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta-digi-arm/recipes-digi/trustfence/trustfence-sign-tools/trustfence-sign-kernel.sh b/meta-digi-arm/recipes-digi/trustfence/trustfence-sign-tools/trustfence-sign-kernel.sh index 2548fb0ed..2c51850ec 100755 --- a/meta-digi-arm/recipes-digi/trustfence/trustfence-sign-tools/trustfence-sign-kernel.sh +++ b/meta-digi-arm/recipes-digi/trustfence/trustfence-sign-tools/trustfence-sign-kernel.sh @@ -157,7 +157,7 @@ ivt_uimage_start="$((auth_len - 0x20))" ivt_ram_start="$((CONFIG_RAM_START + ivt_uimage_start))" ivt_size="0x20" csf_ram_start="$((ivt_ram_start + ivt_size))" -entrypoint_uimage_offset="0x1000" +entrypoint_uimage_offset="0x100" entrypoint_ram_start="$((CONFIG_RAM_START + entrypoint_uimage_offset))" entrypoint_size="0x20" header_uimage_offset="0x0"