image: Add TI PMMC image type
PATCH 1/3 image: Add TI PMMC image type
Add a new image type representing TI Power Management Micro-Controller (PMMC) Firmware image type.
--- common/image.c | 1 + include/image.h | 1 + 2 files changed, 2 insertions(+)
common/image.c +1 -0
@@ -167,6 +167,7 @@ static const table_entry_t uimage_type[] = { { IH_TYPE_FPGA, "fpga", "FPGA Image" }, { IH_TYPE_TEE, "tee", "Trusted Execution Environment Image",}, { IH_TYPE_FIRMWARE_IVT, "firmware_ivt", "Firmware with HABv4 IVT" }, + { IH_TYPE_PMMC, "pmmc", "TI Power Management Micro-Controller Firmware",}, { -1, "", "", }, };
include/image.h +1 -0
@@ -269,6 +269,7 @@ enum {IH_TYPE_VYBRIDIMAGE ,/* VYBRID .vyb Image */ IH_TYPE_TEE ,/* Trusted Execution Environment OS Image */ IH_TYPE_FIRMWARE_IVT ,/* Firmware Image with HABv4 IVT */ +IH_TYPE_PMMC ,/* TI Power Management Micro-Controller Firmware */ IH_TYPE_COUNT, /* Number of image types */ };
Signature · 1 line
2.13.0
PATCH 2/3 ARM: k2g: Add FIT image handler for PMMC firmware
The PMMC firmware should be bundled into a FIT image on HS devices to allow authentication/decryption, add a handler to process this PMMC firmware.
--- board/ti/ks2_evm/board_k2g.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+)
board/ti/ks2_evm/board_k2g.c +21 -0
@@ -13,6 +13,7 @@#include <asm/arch/mmc_host_def.h> #include <fdtdec.h> #include <i2c.h> +#include <remoteproc.h> #include "mux-k2g.h" #include "../common/board_detect.h"
@@ -353,3 +354,23 @@ int get_num_eth_ports(void) return sizeof(eth_priv_cfg) / sizeof(struct eth_priv_t); }#endif + +#ifdef CONFIG_TI_SECURE_DEVICE +void board_pmmc_image_process (ulong pmmc_image,size_t pmmc_size) +{ +int id =getenv_ulong ("dev_pmmc" ,10 ,0 ); +int ret; + +if (!rproc_is_initialized ()) +rproc_init (); + + ret =rproc_load (id, pmmc_image, pmmc_size); +printf ("Load Remote Processor %d with data at addr=0x%08lx %u bytes:%s\n" , + id, pmmc_image, pmmc_size, ret ?" Failed!" :" Success!" ); + +if (!ret) +rproc_start (id); +} + +U_BOOT_FIT_LOADABLE_HANDLER (IH_TYPE_PMMC , board_pmmc_image_process); +#endif
Signature · 1 line
2.13.0
PATCH 2/3 ARM: k2g: Add FIT image handler for PMMC firmware
Quoted 5 lines · Andrew F. Davis
The PMMC firmware should be bundled into a FIT image on HS devices to allow authentication/decryption, add a handler to process this PMMC firmware.
Signed-off-by Andrew F. Davis <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20170912/9dc63943/attachment.sig>
PATCH 3/3 configs: k2g_evm: Remove PMMC loading environment commands
In reply to Andrew F. DavisThe PMMC firmware should be bundled with the FIT image for HS devices, remove the steps that load and install this firmware outside of FIT.
--- include/configs/k2g_evm.h | 1 - 1 file changed, 1 deletion(-)
include/configs/k2g_evm.h +0 -1
@@ -69,7 +69,6 @@"run envboot; " \"run run_mon_hs; " \"run init_${boot}; " \ -"run set_name_pmmc get_pmmc_${boot} run_pmmc; " \"run get_fit_${boot}; " \ "bootm ${fit_loadaddr}#${name_fdt}"#endif
Signature · 1 line
2.13.0
PATCH 3/3 configs: k2g_evm: Remove PMMC loading environment commands
Quoted 4 lines · Andrew F. Davis
The PMMC firmware should be bundled with the FIT image for HS devices, remove the steps that load and install this firmware outside of FIT.
Signed-off-by Andrew F. Davis <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20170912/b74b2e42/attachment.sig>
PATCH 1/3 image: Add TI PMMC image type
In reply to Andrew F. DavisQuoted 4 lines · Andrew F. Davis
Add a new image type representing TI Power Management Micro-Controller (PMMC) Firmware image type.
Signed-off-by Andrew F. Davis <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20170912/921c691e/attachment.sig>