mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-28 23:51:33 +00:00
ARM: imx: hab: panic on authentication failure
Instead of hang()ing the system and thus disallowing any automated recovery possibility from a HAB authentication failure, panic() . The panic() function can be configured to hang() the system after printing an error message, however the default is to reset the system instead. This allows redundant boot to work correctly. In case the primary or secondary image cannot be authenticated, the system reboots and bootrom can try to start the other one. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Fabio Estevam <festevam@gmail.com> Cc: NXP i.MX U-Boot Team <uboot-imx@nxp.com> Cc: Peng Fan <peng.fan@nxp.com> Cc: Stefano Babic <sbabic@denx.de> Reviewed-by: Fabio Estevam <festevam@gmail.com>
This commit is contained in:
parent
10e959a1ca
commit
1e7a69f661
1 changed files with 2 additions and 4 deletions
|
@ -293,8 +293,7 @@ __weak void __noreturn jump_to_image_no_args(struct spl_image_info *spl_image)
|
|||
CSF_PAD_SIZE, offset)) {
|
||||
image_entry();
|
||||
} else {
|
||||
puts("spl: ERROR: image authentication fail\n");
|
||||
hang();
|
||||
panic("spl: ERROR: image authentication fail\n");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -320,8 +319,7 @@ void board_spl_fit_post_load(ulong load_addr, size_t length)
|
|||
if (imx_hab_authenticate_image(load_addr,
|
||||
offset + IVT_SIZE + CSF_PAD_SIZE,
|
||||
offset)) {
|
||||
puts("spl: ERROR: image authentication unsuccessful\n");
|
||||
hang();
|
||||
panic("spl: ERROR: image authentication unsuccessful\n");
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue