diff options
author | Samuel Holland <samuel@sholland.org> | 2022-03-18 08:00:43 +0300 |
---|---|---|
committer | Andre Przywara <andre.przywara@arm.com> | 2022-04-05 01:24:17 +0300 |
commit | e9e87ec47c756b1ee2b0a6680488d60adb2079a9 (patch) | |
tree | 529b28bd135900937ed59c63454a8b9d67ec6dbe /boot/image.c | |
parent | 8c621f4c3b794973a0dd76623cab6069d89fb3d7 (diff) | |
download | u-boot-e9e87ec47c756b1ee2b0a6680488d60adb2079a9.tar.xz |
tools: mkimage: Add Allwinner TOC0 support
Most Allwinner sunxi SoCs have separate boot ROMs in non-secure and
secure mode. The "non-secure" or "normal" boot ROM (NBROM) uses the
existing sunxi_egon image type. The secure boot ROM (SBROM) uses a
completely different image type, known as TOC0.
A TOC0 image is composed of a header and two or more items. One item
is the firmware binary. The others form a chain linking the firmware
signature to the root-of-trust public key (ROTPK), which has its hash
burned in the SoC's eFuses. Signatures are made using RSA-2048 + SHA256.
The pseudo-ASN.1 structure is manually assembled; this is done to work
around bugs/quirks in the boot ROM, which vary between SoCs. This TOC0
implementation has been verified to work with the A50, A64, H5, H6,
and H616 SBROMs, and it may work with other SoCs.
Signed-off-by: Samuel Holland <samuel@sholland.org>
Acked-by: Andre Przywara <andre.przywara@arm.com>
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Diffstat (limited to 'boot/image.c')
-rw-r--r-- | boot/image.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/boot/image.c b/boot/image.c index 121df0c838..5dcb55ba46 100644 --- a/boot/image.c +++ b/boot/image.c @@ -178,6 +178,7 @@ static const table_entry_t uimage_type[] = { { IH_TYPE_MTKIMAGE, "mtk_image", "MediaTek BootROM loadable Image" }, { IH_TYPE_COPRO, "copro", "Coprocessor Image"}, { IH_TYPE_SUNXI_EGON, "sunxi_egon", "Allwinner eGON Boot Image" }, + { IH_TYPE_SUNXI_TOC0, "sunxi_toc0", "Allwinner TOC0 Boot Image" }, { -1, "", "", }, }; |