diff options
author | Marek Vasut <marek.vasut+renesas@mailbox.org> | 2025-06-15 12:51:08 +0200 |
---|---|---|
committer | Marek Vasut <marek.vasut+renesas@mailbox.org> | 2025-07-10 19:26:55 +0200 |
commit | 26758c24b913e54ca521f782fbf1c52dd4ee540e (patch) | |
tree | 226099eaff4d95808c69ef18bb5b7592fa89e42b | |
parent | f85d97b26c8773d6261f0db76278cdc01a698130 (diff) |
arm64: renesas: Add Renesas R-Car Gen4 SCIF/HSCIF loader SREC generation
Add Renesas R-Car Gen4 SCIF/HSCIF loader compatible SREC generation.
This is a regular U-Boot SPL SREC augmented with a short header which
describes where to store the received data and how much data to store.
This header is interpreted by the R-Car Gen4 BootROM SCIF/HSCIF loader.
Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
-rw-r--r-- | arch/arm/mach-renesas/Makefile | 10 | ||||
-rw-r--r-- | common/spl/Kconfig | 2 |
2 files changed, 11 insertions, 1 deletions
diff --git a/arch/arm/mach-renesas/Makefile b/arch/arm/mach-renesas/Makefile index 3409437d75a..9165ceab4a3 100644 --- a/arch/arm/mach-renesas/Makefile +++ b/arch/arm/mach-renesas/Makefile @@ -34,6 +34,15 @@ else srec_cat_le_cmd := "-l-e-constant" endif +ifneq ($(CONFIG_RCAR_GEN4),) +quiet_cmd_srec_cat = SRECCAT $@ + cmd_srec_cat = srec_cat -output $@ -M 8 $< -M 8 \ + -Output_Block_Size 16 \ + -generate 0xeb203000 0xeb203154 $(srec_cat_le_cmd) 0x0 4 \ + -generate 0xeb203154 0xeb203158 $(srec_cat_le_cmd) $(CONFIG_SPL_TEXT_BASE) 4 \ + -generate 0xeb203158 0xeb203264 $(srec_cat_le_cmd) 0x0 4 \ + -generate 0xeb203264 0xeb203268 $(srec_cat_le_cmd) $$(( ( $2 + 4 ) / 4 )) 4 +else ifneq ($(CONFIG_R8A774C0)$(CONFIG_R8A77990)$(CONFIG_R8A77995),) # # The first 6 generate statements generate the R-Car Gen3 SCIF loader header. @@ -90,6 +99,7 @@ quiet_cmd_srec_cat = SRECCAT $@ -generate 0xe6301154 0xe6301158 $(srec_cat_le_cmd) $(CONFIG_SPL_TEXT_BASE) 4 \ -generate 0xe6301264 0xe6301268 $(srec_cat_le_cmd) $2 4 endif +endif spl/u-boot-spl.scif: spl/u-boot-spl.srec spl/u-boot-spl.bin $(call cmd,srec_cat,$(shell wc -c spl/u-boot-spl.bin | awk '{printf("0x%08x\n",$$1)}')) diff --git a/common/spl/Kconfig b/common/spl/Kconfig index 9a17ccb2d3d..4e26b3940d8 100644 --- a/common/spl/Kconfig +++ b/common/spl/Kconfig @@ -1598,7 +1598,7 @@ config SPL_OPENSBI_SCRATCH_OPTIONS config SPL_TARGET string "Addtional build targets for 'make'" default "spl/u-boot-spl.srec" if RCAR_GEN2 - default "spl/u-boot-spl.scif" if RCAR_GEN3 + default "spl/u-boot-spl.scif" if RCAR_64 default "" help On some platforms we need to have 'make' run additional build target |