mirror of
https://github.com/u-boot/u-boot.git
synced 2025-05-08 19:11:53 +00:00
stm32mp: stm32prog: add FIP header support
Add support of TF-A FIP header in command stm32prog for all the boot partition and not only the STM32IMAGE. This patch is a preliminary patch to support FIP as second boot stage after TF-A BL2 when CONFIG_TFABOOT is activated for trusted boot chain. The FIP is archive binary loaded by TF-A BL2, which contains the secure OS = OP-TEE and the non secure firmware and device tree = U-Boot. Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com> Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
This commit is contained in:
parent
0441b48570
commit
4fb7b3e108
4 changed files with 63 additions and 36 deletions
|
@ -37,8 +37,14 @@ enum stm32prog_link_t {
|
|||
LINK_UNDEFINED,
|
||||
};
|
||||
|
||||
enum stm32prog_header_t {
|
||||
HEADER_NONE,
|
||||
HEADER_STM32IMAGE,
|
||||
HEADER_FIP,
|
||||
};
|
||||
|
||||
struct image_header_s {
|
||||
bool present;
|
||||
enum stm32prog_header_t type;
|
||||
u32 image_checksum;
|
||||
u32 image_length;
|
||||
};
|
||||
|
@ -160,8 +166,8 @@ int stm32prog_pmic_read(struct stm32prog_data *data, u32 offset,
|
|||
int stm32prog_pmic_start(struct stm32prog_data *data);
|
||||
|
||||
/* generic part*/
|
||||
u8 stm32prog_header_check(struct raw_header_s *raw_header,
|
||||
struct image_header_s *header);
|
||||
void stm32prog_header_check(struct raw_header_s *raw_header,
|
||||
struct image_header_s *header);
|
||||
int stm32prog_dfu_init(struct stm32prog_data *data);
|
||||
void stm32prog_next_phase(struct stm32prog_data *data);
|
||||
void stm32prog_do_reset(struct stm32prog_data *data);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue