Skip to contentSkip to conversation

VBE serial part H: Implement VBE on Rockchip RK3399

PATCH Superseded Simon Glass 3 participants 83 messages Feb 9, 2025 – Feb 27, 2025

Subsystems (14)

v2 of 5 Superseded Latest is v5 →

lore
Share & tools
lore
#0 lore raw

v2 cover VBE serial part H: Implement VBE on Rockchip RK3399

This series completes the work to enable VBE on a suitable board. Most of it is rockchip-specific patches to support the VPL phase, i.e. the one which decides which boot patch to take (A, B or recovery).

A good chunk of this series is adding an image for VBE, by creating a new Binman image. Future work in Binman may make this more automated / easier, but for now it is written out in full. The work is undertaken piecemeal so it is easier to review the steps.

VBE allows similar boards to share firmware images, with perhaps just TPL (around 75K) being different for each board. Using a common image for VPL, SPL and U-Boot saves a lot of space in the image and makes builds easier. Of course, each board still needs a separate devicetree.

Here is the layout of the image:

Name Image-pos Size Entry-type Offset Uncomp-size
----------------------------------------------------------------------------------------------

image                                 0   1b960cf  section                    0
  alternates-fdt                   8000     31000  alternates-fdt          8000
    mkimage                        8000     31000  mkimage                    0
      u-boot-tpl                   8048     12a11  u-boot-tpl                48
  vpl                            208000     16200  fit                   208000
    image-vpl                    209400      a5a3  section                 1400
      section                    209400      a5a3  section                    0
        u-boot-vpl-nodtb                    10348  u-boot-vpl-nodtb           0
        u-boot-vpl-bss-pad                     20  u-boot-vpl-bss-pad     10348
    @fdt-SEQ                          0         0  section                    0
  vbe-a                          800000    39b200  section               800000
    spl-a                        800000    100000  fit                        0
      spl                        801400     10c97  section                 1400
        section                  801400     10c97  section                    0
          u-boot-spl-nodtb                  1a908  u-boot-spl-nodtb           0
          u-boot-spl-bss-pad                  1b0  u-boot-spl-bss-pad     1a908
      @fdt-SEQ                        0         0  section                    0
    u-boot-a                     900000    29b200  fit                   100000
      spl                        902400     10c97  section                 2400
        section                  902400     10c97  section                    0
          u-boot-spl-nodtb                  1a908  u-boot-spl-nodtb           0
          u-boot-spl-bss-pad                  1b0  u-boot-spl-bss-pad     1a908
      u-boot                     913200     e4250  section                13200
        u-boot-nodtb             913200     e4250  u-boot-nodtb               0
      @atf-SEQ                        0         0  section                    0
        atf-bl31                      0         0  atf-bl31                   0
      @tee-SEQ                        0         0  section                    0
        tee-os                        0         0  tee-os                     0
      @fdt-SEQ                        0         0  section                    0
  vbe-b                         1000000    39b200  section              1000000
    spl-b                       1000000    100000  fit                        0
      spl                       1001400     10c97  section                 1400
        section                 1001400     10c97  section                    0
          u-boot-spl-nodtb                  1a908  u-boot-spl-nodtb           0
          u-boot-spl-bss-pad                  1b0  u-boot-spl-bss-pad     1a908
      @fdt-SEQ                        0         0  section                    0
    u-boot-b                    1100000    29b200  fit                   100000
      spl                       1102400     10c97  section                 2400
        section                 1102400     10c97  section                    0
          u-boot-spl-nodtb                  1a908  u-boot-spl-nodtb           0
          u-boot-spl-bss-pad                  1b0  u-boot-spl-bss-pad     1a908
      u-boot                    1113200     e4250  section                13200
        u-boot-nodtb            1113200     e4250  u-boot-nodtb               0
      @atf-SEQ                        0         0  section                    0
        atf-bl31                      0         0  atf-bl31                   0
      @tee-SEQ                        0         0  section                    0
        tee-os                        0         0  tee-os                     0
      @fdt-SEQ                        0         0  section                    0
  vbe-recovery                  1800000    39b200  section              1800000
    spl-recovery                1800000    100000  fit                        0
      spl                       1801400     10c97  section                 1400
        section                 1801400     10c97  section                    0
          u-boot-spl-nodtb                  1a908  u-boot-spl-nodtb           0
          u-boot-spl-bss-pad                  1b0  u-boot-spl-bss-pad     1a908
      @fdt-SEQ                        0         0  section                    0
    u-boot-recovery             1900000    29b200  fit                   100000
      spl                       1902400     10c97  section                 2400
        section                 1902400     10c97  section                    0
          u-boot-spl-nodtb                  1a908  u-boot-spl-nodtb           0
          u-boot-spl-bss-pad                  1b0  u-boot-spl-bss-pad     1a908
      u-boot                    1913200     e4250  section                13200
        u-boot-nodtb            1913200     e4250  u-boot-nodtb               0
      @atf-SEQ                        0         0  section                    0
        atf-bl31                      0         0  atf-bl31                   0
      @tee-SEQ                        0         0  section                    0
        tee-os                        0         0  tee-os                     0
      @fdt-SEQ                        0         0  section                    0
  fdtmap                        1b9b200      2ecf  fdtmap               1b9b200

Unfortunately I got a bit lost trying to figure out the bloblist code, despite my being the original author. So for now I have included a revert of a recent patch, so that the logic can be simplified and more in keeping with the original intent. We may in fact need a symbol which specifically says which phase creates the bloblist, but I'm not completely sure of what the reverted patch was trying to achieve.

This is (mostly) the final VBE series, but there are a few loose ends to tidy up:

- cache is disabled in SPL, which slows the boot a little
- pinctrl init needs to be tidied up to avoid warnings
- bloblist logic as above
- bloblist-relocation is partly in board-specific code, partly generic

Other things may become apparently after more usage / testing.

Changes in v2:
- Add new patch to rename TPL_NEEDS_SEPARATE_STACK
- Add new patch with an SPL_HAVE_INIT_STACK option
- Add new patch to use CONFIG_VAL() to obtain the SPL stack
- Reply on existing CONFIG_VAL() to select the VPL stack
- Correct reference to TPL when VPL was intended
- Put this patch before 'Factor out arch and compression'
- Move VPL things into a separate file
- Mention RK3399 with respect to the memory limit
- Move VPL things into a separate file
- Only enable MMC when VPM is in use.
- Rewrite help for VPL_ROCKCHIP_COMMON_BOARD
- Skip spl-boot-order.c for VPL (rather than modifying it)
- Reword commit to mention comments from Jonas
- Rename to rk3399-generic-ddr3
- Update devicetree to match firefly-rk3399
- Use the firefly devicetree as the default for this board
- Move this patch to the end of the series
- Drop 0x8000 offset for SPI
- Add new patch with a bootmeth driver for abrec
- Split out the fixes for skip-at-start into a new patch
- Move this logic into board-specific code
- Move the actual relocation code to a previous board-specific patch

Simon Glass (35):
tpl: Rename TPL_NEEDS_SEPARATE_STACK to TPL_HAVE_INIT_STACK
spl: Add an SPL_HAVE_INIT_STACK option
spl: Use CONFIG_VAL() to obtain the SPL stack
arm: Support a separate stack for VPL
spl: Adjust xPL symbols
spl: Allow VBE to handle xPL size
vbe: Show the margin when using SPL_RELOC
rockchip: Allow RAM init to happen in SPL on rk3399
rockchip: dts: Correct the OS for U-Boot
rockchip: dts: Factor out arch and compression
rockchip: dts: Add an fdtmap
rockchip: dts: Create a template for the FIT
rockchip: dts: Un-indent the FIT template
rockchip: dts: Use the new binman template for the SPI image too
rockchip: dts: Specify the phase in the image
rockchip: Provide a bootstd configuration
rockchip: Add SPL into the main FIT
rockchip: Include a compatible string in each configuration
rockchip: Add a template for SPL
rockchip: Add a VPL image
rockchip: Add TPL alternatives
rockchip: Update rk3399 bootph-tags for VPL
rockchip: Provide a VPL phase on rk3399
rockchip: Add symbols for spl_reloc
rockchip: rk3399: Adjust initial TPL-stack to match SPL
rockchip: Allow SPL to set up SDRAM
rockchip: Add a generic-ddr3 rk3399 board
rockchip: Add documentation for VBE
gitlab: Add an VBE board to the sjg lab
rockchip: Set the skip-at-start property correctly
vbe: Add a bootmeth driver for abrec
rockchip: Update binman image for new skip-at-start setup
RFC: Revert "bloblist: Load the bloblist from the previous loader"
rockchip: Relocate bloblist at the end of the SPL phase
bloblist: Allow using a different bloblist address

 .gitlab-ci.yml                                |   6 +
 arch/arm/cpu/armv7/lowlevel_init.S            |   4 +-
 arch/arm/cpu/armv7/start.S                    |   4 +-
 arch/arm/dts/rk3399-u-boot.dtsi               |  11 +-
 arch/arm/dts/rockchip-u-boot.dtsi             | 324 +++++++++++-------
 arch/arm/dts/rockchip-vpl-u-boot.dtsi         | 166 +++++++++
 arch/arm/include/asm/spl.h                    |   1 +
 arch/arm/lib/crt0.S                           |   6 +-
 arch/arm/lib/crt0_64.S                        |   6 +-
 arch/arm/mach-rockchip/Kconfig                |  39 ++-
 arch/arm/mach-rockchip/Makefile               |  11 +-
 arch/arm/mach-rockchip/rk3399/Kconfig         |  11 +-
 arch/arm/mach-rockchip/spl.c                  |  17 +
 arch/arm/mach-rockchip/tpl.c                  |  12 +-
 arch/arm/mach-rockchip/u-boot-tpl-v8.lds      |  13 +
 arch/arm/mach-rockchip/u-boot-vpl-v8.lds      | 107 ++++++
 arch/arm/mach-rockchip/vpl.c                  |  53 +++
 arch/riscv/cpu/start.S                        |   4 +-
 board/rockchip/evb_rk3399/MAINTAINERS         |   6 +
 boot/vbe_abrec.c                              |  99 ++++++
 cmd/vbe.c                                     |   8 +-
 common/Kconfig                                |  20 ++
 common/bloblist.c                             |  77 ++---
 common/spl/Kconfig                            |  29 +-
 common/spl/Kconfig.tpl                        |  19 +-
 common/spl/Kconfig.vpl                        |  14 +
 common/spl/spl.c                              |   2 +
 common/spl/spl_reloc.c                        |  14 +-
 configs/alt_defconfig                         |   1 +
 configs/anbernic-rgxx3-rk3566_defconfig       |   2 +-
 configs/apalis-tk1_defconfig                  |   1 +
 configs/apalis_t30_defconfig                  |   1 +
 configs/axm_defconfig                         |   1 +
 configs/beaver_defconfig                      |   1 +
 configs/bitmain_antminer_s9_defconfig         |   1 +
 configs/bpi-r2-pro-rk3568_defconfig           |   2 +-
 configs/capricorn_cxg3_defconfig              |   1 +
 configs/cardhu_defconfig                      |   1 +
 configs/cei-tk1-som_defconfig                 |   1 +
 configs/cgtqmx8_defconfig                     |   1 +
 configs/chromebit_mickey_defconfig            |   3 +-
 configs/chromebook_bob_defconfig              |   3 +-
 configs/chromebook_jerry_defconfig            |   3 +-
 configs/chromebook_kevin_defconfig            |   3 +-
 configs/chromebook_minnie_defconfig           |   3 +-
 configs/chromebook_speedy_defconfig           |   3 +-
 configs/ci20_mmc_defconfig                    |   1 +
 configs/clearfog_defconfig                    |   1 +
 configs/clearfog_sata_defconfig               |   1 +
 configs/clearfog_spi_defconfig                |   1 +
 configs/cm3588-nas-rk3588_defconfig           |   2 +-
 configs/colibri_t20_defconfig                 |   1 +
 configs/colibri_t30_defconfig                 |   1 +
 configs/controlcenterdc_defconfig             |   1 +
 configs/coolpi-4b-rk3588s_defconfig           |   2 +-
 configs/coolpi-cm5-evb-rk3588_defconfig       |   2 +-
 configs/coolpi-cm5-genbook-rk3588_defconfig   |   2 +-
 configs/corvus_defconfig                      |   1 +
 configs/da850evm_defconfig                    |   1 +
 configs/da850evm_nand_defconfig               |   1 +
 configs/dalmore_defconfig                     |   1 +
 configs/db-88f6720_defconfig                  |   1 +
 configs/db-88f6820-amc_defconfig              |   1 +
 configs/db-88f6820-amc_nand_defconfig         |   1 +
 configs/db-88f6820-gp_defconfig               |   1 +
 configs/db-mv784mp-gp_defconfig               |   1 +
 configs/ds116_defconfig                       |   1 +
 configs/ds414_defconfig                       |   1 +
 configs/eaidk-610-rk3399_defconfig            |   2 +-
 configs/endeavoru_defconfig                   |   1 +
 configs/evb-px30_defconfig                    |   2 +-
 configs/evb-px5_defconfig                     |   3 +-
 configs/evb-rk3036_defconfig                  |   3 +-
 configs/evb-rk3229_defconfig                  |   2 +-
 configs/evb-rk3288_defconfig                  |   3 +-
 configs/evb-rk3308_defconfig                  |   2 +-
 configs/evb-rk3328_defconfig                  |   2 +-
 configs/evb-rk3399_defconfig                  |   2 +-
 configs/evb-rk3568_defconfig                  |   2 +-
 configs/evb-rk3588_defconfig                  |   2 +-
 configs/ficus-rk3399_defconfig                |   2 +-
 configs/firefly-px30_defconfig                |   2 +-
 configs/firefly-rk3288_defconfig              |   2 +-
 configs/firefly-rk3399_defconfig              |   2 +-
 .../gardena-smart-gateway-at91sam_defconfig   |   1 +
 configs/generic-rk3568_defconfig              |   2 +-
 configs/generic-rk3588_defconfig              |   2 +-
 configs/gose_defconfig                        |   1 +
 configs/grouper_defconfig                     |   1 +
 configs/harmony_defconfig                     |   1 +
 configs/helios4_defconfig                     |   1 +
 configs/ideapad-yoga-11_defconfig             |   1 +
 configs/imx28_xea_defconfig                   |   1 +
 configs/imx8mm-cl-iot-gate-optee_defconfig    |   1 +
 configs/imx8mm-cl-iot-gate_defconfig          |   1 +
 configs/imx8mm-icore-mx8mm-ctouch2_defconfig  |   1 +
 configs/imx8mm-icore-mx8mm-edimm2.2_defconfig |   1 +
 configs/imx8mm-mx8menlo_defconfig             |   1 +
 configs/imx8mm-phygate-tauri-l_defconfig      |   1 +
 configs/imx8mm_beacon_defconfig               |   1 +
 configs/imx8mm_beacon_fspi_defconfig          |   1 +
 configs/imx8mm_data_modul_edm_sbc_defconfig   |   1 +
 configs/imx8mm_evk_defconfig                  |   1 +
 configs/imx8mm_evk_fspi_defconfig             |   1 +
 configs/imx8mm_phg_defconfig                  |   1 +
 configs/imx8mm_venice_defconfig               |   1 +
 configs/imx8mn_beacon_2g_defconfig            |   1 +
 configs/imx8mn_beacon_defconfig               |   1 +
 configs/imx8mn_beacon_fspi_defconfig          |   1 +
 configs/imx8mn_bsh_smm_s2_defconfig           |   1 +
 configs/imx8mn_bsh_smm_s2pro_defconfig        |   1 +
 configs/imx8mn_ddr4_evk_defconfig             |   1 +
 configs/imx8mn_evk_defconfig                  |   1 +
 configs/imx8mn_var_som_defconfig              |   1 +
 configs/imx8mn_venice_defconfig               |   1 +
 configs/imx8mp-icore-mx8mp-edimm2.2_defconfig |   1 +
 configs/imx8mp_beacon_defconfig               |   1 +
 configs/imx8mp_data_modul_edm_sbc_defconfig   |   1 +
 configs/imx8mp_debix_model_a_defconfig        |   1 +
 configs/imx8mp_dhsom.config                   |   1 +
 configs/imx8mp_evk_defconfig                  |   1 +
 configs/imx8mp_navqp_defconfig                |   1 +
 configs/imx8mp_rsb3720a1_4G_defconfig         |   1 +
 configs/imx8mp_rsb3720a1_6G_defconfig         |   1 +
 configs/imx8mp_venice_defconfig               |   1 +
 configs/imx8mq_cm_defconfig                   |   1 +
 configs/imx8mq_evk_defconfig                  |   1 +
 configs/imx8mq_phanbell_defconfig             |   1 +
 configs/imx8mq_reform2_defconfig              |   1 +
 configs/imx8qm_dmsse20a1_defconfig            |   1 +
 configs/imx8qm_mek_defconfig                  |   1 +
 configs/imx8qxp_mek_defconfig                 |   1 +
 configs/imx8ulp_evk_defconfig                 |   1 +
 configs/imx93-phycore_defconfig               |   1 +
 configs/imx93_11x11_evk_defconfig             |   1 +
 configs/imx93_9x9_qsb_defconfig               |   1 +
 configs/imx93_9x9_qsb_inline_ecc_defconfig    |   1 +
 configs/imx93_var_som_defconfig               |   1 +
 configs/jaguar-rk3588_defconfig               |   2 +-
 configs/jetson-tk1_defconfig                  |   1 +
 configs/k2e_evm_defconfig                     |   1 +
 configs/k2g_evm_defconfig                     |   1 +
 configs/k2hk_evm_defconfig                    |   1 +
 configs/k2l_evm_defconfig                     |   1 +
 configs/khadas-edge-captain-rk3399_defconfig  |   2 +-
 configs/khadas-edge-rk3399_defconfig          |   2 +-
 configs/khadas-edge-v-rk3399_defconfig        |   2 +-
 configs/khadas-edge2-rk3588s_defconfig        |   2 +-
 configs/koelsch_defconfig                     |   1 +
 configs/kontron-sl-mx8mm_defconfig            |   1 +
 configs/kontron_pitx_imx8m_defconfig          |   1 +
 configs/kontron_sl28_defconfig                |   1 +
 configs/kylin-rk3036_defconfig                |   3 +-
 configs/lager_defconfig                       |   1 +
 configs/leez-rk3399_defconfig                 |   2 +-
 configs/librem5_defconfig                     |   1 +
 configs/ls1021aiot_sdcard_defconfig           |   1 +
 configs/ls1021aqds_nand_defconfig             |   1 +
 configs/ls1021aqds_sdcard_ifc_defconfig       |   1 +
 configs/ls1021aqds_sdcard_qspi_defconfig      |   1 +
 configs/ls1021atsn_sdcard_defconfig           |   1 +
 ...s1021atwr_sdcard_ifc_SECURE_BOOT_defconfig |   1 +
 configs/ls1021atwr_sdcard_ifc_defconfig       |   1 +
 configs/ls1021atwr_sdcard_qspi_defconfig      |   1 +
 configs/ls2080aqds_nand_defconfig             |   1 +
 configs/ls2080ardb_nand_defconfig             |   1 +
 configs/lubancat-2-rk3568_defconfig           |   2 +-
 configs/m53menlo_defconfig                    |   1 +
 configs/maxbcm_defconfig                      |   1 +
 configs/medcom-wide_defconfig                 |   1 +
 configs/microblaze-generic_defconfig          |   1 +
 configs/miqi-rk3288_defconfig                 |   2 +-
 configs/mk808_defconfig                       |   5 +-
 configs/msc_sm2s_imx8mp_defconfig             |   1 +
 configs/mt7629_rfb_defconfig                  |   1 +
 configs/n2350_defconfig                       |   1 +
 configs/nanopc-t4-rk3399_defconfig            |   2 +-
 configs/nanopc-t6-rk3588_defconfig            |   2 +-
 configs/nanopi-m4-2gb-rk3399_defconfig        |   2 +-
 configs/nanopi-m4-rk3399_defconfig            |   2 +-
 configs/nanopi-m4b-rk3399_defconfig           |   2 +-
 configs/nanopi-neo4-rk3399_defconfig          |   2 +-
 configs/nanopi-r2c-plus-rk3328_defconfig      |   2 +-
 configs/nanopi-r2c-rk3328_defconfig           |   2 +-
 configs/nanopi-r2s-plus-rk3328_defconfig      |   2 +-
 configs/nanopi-r2s-rk3328_defconfig           |   2 +-
 configs/nanopi-r3s-rk3566_defconfig           |   2 +-
 configs/nanopi-r4s-rk3399_defconfig           |   2 +-
 configs/nanopi-r5c-rk3568_defconfig           |   2 +-
 configs/nanopi-r5s-rk3568_defconfig           |   2 +-
 configs/nanopi-r6c-rk3588s_defconfig          |   2 +-
 configs/nanopi-r6s-rk3588s_defconfig          |   2 +-
 configs/neu2-io-rv1126_defconfig              |   2 +-
 configs/neu6a-io-rk3588_defconfig             |   2 +-
 configs/neu6b-io-rk3588_defconfig             |   2 +-
 configs/nova-rk3588s_defconfig                |   2 +-
 configs/nyan-big_defconfig                    |   1 +
 configs/odroid-go2_defconfig                  |   2 +-
 configs/odroid-m1-rk3568_defconfig            |   2 +-
 configs/odroid-m1s-rk3566_defconfig           |   2 +-
 configs/odroid-m2-rk3588s_defconfig           |   2 +-
 configs/omapl138_lcdk_defconfig               |   1 +
 configs/openpiton_riscv64_spl_defconfig       |   1 +
 configs/orangepi-3b-rk3566_defconfig          |   2 +-
 configs/orangepi-5-plus-rk3588_defconfig      |   2 +-
 configs/orangepi-5-rk3588s_defconfig          |   2 +-
 configs/orangepi-r1-plus-lts-rk3328_defconfig |   2 +-
 configs/orangepi-r1-plus-rk3328_defconfig     |   2 +-
 configs/orangepi-rk3399_defconfig             |   2 +-
 configs/paz00_defconfig                       |   1 +
 configs/phycore-imx8mm_defconfig              |   1 +
 configs/phycore-imx8mp_defconfig              |   1 +
 configs/phycore-rk3288_defconfig              |   3 +-
 configs/pico-imx8mq_defconfig                 |   1 +
 configs/pinebook-pro-rk3399_defconfig         |   2 +-
 configs/pinephone-pro-rk3399_defconfig        |   2 +-
 configs/pinetab2-rk3566_defconfig             |   2 +-
 configs/plutux_defconfig                      |   1 +
 configs/popmetal-rk3288_defconfig             |   3 +-
 configs/porter_defconfig                      |   1 +
 configs/powkiddy-x55-rk3566_defconfig         |   2 +-
 configs/puma-rk3399_defconfig                 |   2 +-
 configs/px30-core-ctouch2-of10-px30_defconfig |   2 +-
 configs/px30-core-ctouch2-px30_defconfig      |   2 +-
 configs/px30-core-edimm2.2-px30_defconfig     |   2 +-
 configs/qc750_defconfig                       |   1 +
 configs/qnap-ts433-rk3568_defconfig           |   2 +-
 configs/quartz64-a-rk3566_defconfig           |   2 +-
 configs/quartz64-b-rk3566_defconfig           |   2 +-
 configs/quartzpro64-rk3588_defconfig          |   2 +-
 configs/r8a77970_eagle_defconfig              |   1 +
 configs/r8a77970_v3msk_defconfig              |   1 +
 configs/r8a77980_condor_defconfig             |   1 +
 configs/r8a77980_v3hsk_defconfig              |   1 +
 configs/r8a77990_ebisu_defconfig              |   1 +
 configs/r8a77995_draak_defconfig              |   1 +
 configs/radxa-cm3-io-rk3566_defconfig         |   2 +-
 configs/radxa-e25-rk3568_defconfig            |   2 +-
 configs/radxa-zero-3-rk3566_defconfig         |   2 +-
 configs/rcar3_salvator-x_defconfig            |   1 +
 configs/rcar3_ulcb_defconfig                  |   1 +
 configs/rk3399-generic-ddr3_defconfig         | 125 +++++++
 configs/roc-cc-rk3308_defconfig               |   2 +-
 configs/roc-cc-rk3328_defconfig               |   2 +-
 configs/roc-pc-mezzanine-rk3399_defconfig     |   2 +-
 configs/roc-pc-rk3399_defconfig               |   2 +-
 configs/rock-3a-rk3568_defconfig              |   2 +-
 configs/rock-3b-rk3568_defconfig              |   2 +-
 configs/rock-3c-rk3566_defconfig              |   2 +-
 configs/rock-4c-plus-rk3399_defconfig         |   2 +-
 configs/rock-4se-rk3399_defconfig             |   2 +-
 configs/rock-5-itx-rk3588_defconfig           |   2 +-
 configs/rock-5c-rk3588s_defconfig             |   2 +-
 configs/rock-pi-4-rk3399_defconfig            |   2 +-
 configs/rock-pi-4c-rk3399_defconfig           |   2 +-
 configs/rock-pi-e-rk3328_defconfig            |   2 +-
 configs/rock-pi-e-v3-rk3328_defconfig         |   2 +-
 configs/rock-pi-n10-rk3399pro_defconfig       |   2 +-
 configs/rock-pi-n8-rk3288_defconfig           |   3 +-
 configs/rock-pi-s-rk3308_defconfig            |   2 +-
 configs/rock-s0-rk3308_defconfig              |   2 +-
 configs/rock2_defconfig                       |   3 +-
 configs/rock5a-rk3588s_defconfig              |   2 +-
 configs/rock5b-rk3588_defconfig               |   2 +-
 configs/rock64-rk3328_defconfig               |   2 +-
 configs/rock960-rk3399_defconfig              |   2 +-
 configs/rock_defconfig                        |   3 +-
 configs/rockpro64-rk3399_defconfig            |   2 +-
 configs/sama5d27_giantboard_defconfig         |   1 +
 configs/sama5d27_som1_ek_mmc1_defconfig       |   1 +
 configs/sama5d27_som1_ek_mmc_defconfig        |   1 +
 configs/sama5d27_som1_ek_qspiflash_defconfig  |   1 +
 configs/sama5d27_wlsom1_ek_mmc_defconfig      |   1 +
 .../sama5d27_wlsom1_ek_qspiflash_defconfig    |   1 +
 configs/sama5d2_icp_mmc_defconfig             |   1 +
 configs/sama5d2_xplained_emmc_defconfig       |   1 +
 configs/sama5d2_xplained_mmc_defconfig        |   1 +
 configs/sama5d2_xplained_qspiflash_defconfig  |   1 +
 configs/sama5d2_xplained_spiflash_defconfig   |   1 +
 configs/sama5d3_xplained_mmc_defconfig        |   1 +
 configs/sama5d3_xplained_nandflash_defconfig  |   1 +
 configs/sama5d3xek_mmc_defconfig              |   1 +
 configs/sama5d3xek_nandflash_defconfig        |   1 +
 configs/sama5d3xek_spiflash_defconfig         |   1 +
 configs/sama5d4_xplained_mmc_defconfig        |   1 +
 configs/sama5d4_xplained_nandflash_defconfig  |   1 +
 configs/sama5d4_xplained_spiflash_defconfig   |   1 +
 configs/sama5d4ek_mmc_defconfig               |   1 +
 configs/sama5d4ek_nandflash_defconfig         |   1 +
 configs/sama5d4ek_spiflash_defconfig          |   1 +
 configs/seaboard_defconfig                    |   1 +
 configs/sifive_unleashed_defconfig            |   1 +
 configs/sifive_unmatched_defconfig            |   1 +
 configs/sige7-rk3588_defconfig                |   2 +-
 configs/silinux_ek874_defconfig               |   1 +
 configs/silk_defconfig                        |   1 +
 configs/smartweb_defconfig                    |   1 +
 configs/socfpga_agilex5_defconfig             |   1 +
 configs/socfpga_agilex_atf_defconfig          |   1 +
 configs/socfpga_agilex_defconfig              |   1 +
 configs/socfpga_agilex_vab_defconfig          |   1 +
 configs/socfpga_arria10_defconfig             |   1 +
 configs/socfpga_arria5_defconfig              |   1 +
 configs/socfpga_cyclone5_defconfig            |   1 +
 configs/socfpga_dbm_soc1_defconfig            |   1 +
 configs/socfpga_de0_nano_soc_defconfig        |   1 +
 configs/socfpga_de10_nano_defconfig           |   1 +
 configs/socfpga_de10_standard_defconfig       |   1 +
 configs/socfpga_de1_soc_defconfig             |   1 +
 configs/socfpga_is1_defconfig                 |   1 +
 configs/socfpga_mcvevk_defconfig              |   1 +
 configs/socfpga_n5x_atf_defconfig             |   1 +
 configs/socfpga_n5x_defconfig                 |   1 +
 configs/socfpga_n5x_vab_defconfig             |   1 +
 configs/socfpga_secu1_defconfig               |   1 +
 configs/socfpga_sockit_defconfig              |   1 +
 configs/socfpga_socrates_defconfig            |   1 +
 configs/socfpga_sr1500_defconfig              |   1 +
 configs/socfpga_stratix10_atf_defconfig       |   1 +
 configs/socfpga_stratix10_defconfig           |   1 +
 configs/socfpga_vining_fpga_defconfig         |   1 +
 configs/sonoff-ihost-rv1126_defconfig         |   2 +-
 configs/soquartz-blade-rk3566_defconfig       |   2 +-
 configs/soquartz-cm4-rk3566_defconfig         |   2 +-
 configs/soquartz-model-a-rk3566_defconfig     |   2 +-
 configs/starfive_visionfive2_defconfig        |   1 +
 ...stm32mp15-icore-stm32mp1-ctouch2_defconfig |   1 +
 ...tm32mp15-icore-stm32mp1-edimm2.2_defconfig |   1 +
 ...-microgea-stm32mp1-microdev2-of7_defconfig |   1 +
 ...mp15-microgea-stm32mp1-microdev2_defconfig |   1 +
 configs/stm32mp15_basic_defconfig             |   1 +
 configs/stm32mp15_dhsom.config                |   1 +
 configs/stout_defconfig                       |   1 +
 configs/surface-rt_defconfig                  |   1 +
 configs/syzygy_hub_defconfig                  |   1 +
 configs/taurus_defconfig                      |   1 +
 configs/tec-ng_defconfig                      |   1 +
 configs/tec_defconfig                         |   1 +
 configs/theadorable_debug_defconfig           |   1 +
 configs/tiger-rk3588_defconfig                |   2 +-
 configs/tinker-rk3288_defconfig               |   2 +-
 configs/tinker-s-rk3288_defconfig             |   2 +-
 configs/topic_miami_defconfig                 |   1 +
 configs/topic_miamilite_defconfig             |   1 +
 configs/topic_miamiplus_defconfig             |   1 +
 configs/toybrick-rk3588_defconfig             |   2 +-
 configs/transformer_t20_defconfig             |   1 +
 configs/transformer_t30_defconfig             |   1 +
 configs/trimslice_defconfig                   |   1 +
 configs/turing-rk1-rk3588_defconfig           |   2 +-
 configs/turris_omnia_defconfig                |   1 +
 configs/uniphier_ld4_sld8_defconfig           |   1 +
 configs/uniphier_v7_defconfig                 |   1 +
 configs/venice2_defconfig                     |   1 +
 configs/ventana_defconfig                     |   1 +
 configs/verdin-imx8mm_defconfig               |   1 +
 configs/verdin-imx8mp_defconfig               |   1 +
 configs/vyasa-rk3288_defconfig                |   3 +-
 configs/work_92105_defconfig                  |   1 +
 configs/x3_t30_defconfig                      |   1 +
 configs/x530_defconfig                        |   1 +
 configs/xilinx_mbv32_defconfig                |   1 +
 configs/xilinx_mbv32_smode_defconfig          |   1 +
 configs/xilinx_mbv64_defconfig                |   1 +
 configs/xilinx_mbv64_smode_defconfig          |   1 +
 configs/xilinx_zynq_virt_defconfig            |   1 +
 configs/xilinx_zynqmp_kria_defconfig          |   1 +
 configs/xilinx_zynqmp_mini_emmc0_defconfig    |   1 +
 configs/xilinx_zynqmp_mini_emmc1_defconfig    |   1 +
 configs/xilinx_zynqmp_mini_qspi_defconfig     |   1 +
 configs/xilinx_zynqmp_virt_defconfig          |   1 +
 configs/zynq_cse_nand_defconfig               |   1 +
 configs/zynq_cse_nor_defconfig                |   1 +
 configs/zynq_cse_qspi_defconfig               |   1 +
 doc/board/rockchip/rockchip.rst               |  13 +
 drivers/ram/rockchip/sdram_rk3399.c           |   6 +-
 include/bloblist.h                            |  10 -
 include/vbe.h                                 |   3 +
 378 files changed, 1367 insertions(+), 360 deletions(-)
 create mode 100644 arch/arm/dts/rockchip-vpl-u-boot.dtsi
 create mode 100644 arch/arm/mach-rockchip/u-boot-vpl-v8.lds
 create mode 100644 arch/arm/mach-rockchip/vpl.c
 create mode 100644 configs/rk3399-generic-ddr3_defconfig
Signature · 1 line
2.43.0
#1 lore raw

PATCH v2 1/35 tpl: Rename TPL_NEEDS_SEPARATE_STACK to TPL_HAVE_INIT_STACK

The most common word for features that make a platform work is to use 'HAVE_xxx'. Rename this option to match.

Update the help to use the word 'phase' rather than 'stage', since that is the current terminology. Also clarify that, absent this setting, the stack pointer generally comes from the value used by U-Boot proper, rather than SPL.

Move the option just above TPL_STACK which depends on it.

---

Changes in v2:
- Add new patch to rename TPL_NEEDS_SEPARATE_STACK

 arch/arm/lib/crt0.S            |  2 +-
 arch/arm/lib/crt0_64.S         |  2 +-
 arch/arm/mach-rockchip/Kconfig | 14 +++++++-------
 common/spl/Kconfig.tpl         | 19 ++++++++++---------
 configs/mk808_defconfig        |  2 +-
 5 files changed, 20 insertions(+), 19 deletions(-)
arch/arm/lib/crt0.S +1 -1
index a691d844847..a7e6f50d39a 100644
@@ -100,7 +100,7 @@ ENTRY(_main)
  * Set up initial C runtime environment and call board_init_f(0).
  */
 
-#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_NEEDS_SEPARATE_STACK)
+#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
 	ldr	r0, =(CONFIG_TPL_STACK)
 #elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_STACK)
 	ldr	r0, =(CONFIG_SPL_STACK)
arch/arm/lib/crt0_64.S +1 -1
index 32401f544a7..62a0abe1fed 100644
@@ -69,7 +69,7 @@ ENTRY(_main)
 /*
  * Set up initial C runtime environment and call board_init_f(0).
  */
-#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_NEEDS_SEPARATE_STACK)
+#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
 	ldr	x0, =(CONFIG_TPL_STACK)
 #elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_STACK)
 	ldr	x0, =(CONFIG_SPL_STACK)
arch/arm/mach-rockchip/Kconfig +7 -7
index 4d3157b2edd..4c515593718 100644
@@ -9,7 +9,7 @@ config ROCKCHIP_PX30
 	select SPL
 	select TPL
 	select TPL_TINY_FRAMEWORK if TPL
-	select TPL_NEEDS_SEPARATE_STACK if TPL
+	select TPL_HAVE_INIT_STACK if TPL
 	imply SPL_SEPARATE_BSS
 	select SPL_SERIAL
 	select TPL_SERIAL
@@ -106,7 +106,7 @@ config ROCKCHIP_RK322X
 	select TPL
 	select TPL_DM
 	select TPL_OF_LIBFDT
-	select TPL_NEEDS_SEPARATE_STACK if TPL
+	select TPL_HAVE_INIT_STACK if TPL
 	select SPL_DRIVERS_MISC
 	imply ROCKCHIP_COMMON_BOARD
 	imply SPL_SERIAL
@@ -139,7 +139,7 @@ config ROCKCHIP_RK3288
 	imply TPL_DRIVERS_MISC
 	imply TPL_LIBCOMMON_SUPPORT
 	imply TPL_LIBGENERIC_SUPPORT
-	imply TPL_NEEDS_SEPARATE_STACK
+	imply TPL_HAVE_INIT_STACK
 	imply TPL_OF_CONTROL
 	imply TPL_OF_PLATDATA
 	imply TPL_RAM
@@ -197,7 +197,7 @@ config ROCKCHIP_RK3328
 	select SPL
 	select SUPPORT_TPL
 	select TPL
-	select TPL_NEEDS_SEPARATE_STACK if TPL
+	select TPL_HAVE_INIT_STACK if TPL
 	imply ARMV8_CRYPTO
 	imply ARMV8_SET_SMPEN
 	imply MISC
@@ -225,7 +225,7 @@ config ROCKCHIP_RK3368
 	select ARM64
 	select SUPPORT_SPL
 	select SUPPORT_TPL
-	select TPL_NEEDS_SEPARATE_STACK if TPL
+	select TPL_HAVE_INIT_STACK if TPL
 	imply ROCKCHIP_COMMON_BOARD
 	imply SPL_ROCKCHIP_COMMON_BOARD
 	imply SPL_SEPARATE_BSS
@@ -257,7 +257,7 @@ config ROCKCHIP_RK3399
 	select SPL_RAM if SPL
 	select SPL_REGMAP if SPL
 	select SPL_SYSCON if SPL
-	select TPL_NEEDS_SEPARATE_STACK if TPL
+	select TPL_HAVE_INIT_STACK if TPL
 	select SPL_SEPARATE_BSS
 	select CLK
 	select FIT
@@ -392,7 +392,7 @@ config ROCKCHIP_RV1126
 	select SKIP_LOWLEVEL_INIT_ONLY
 	select TPL
 	select SUPPORT_TPL
-	select TPL_NEEDS_SEPARATE_STACK
+	select TPL_HAVE_INIT_STACK
 	select TPL_ROCKCHIP_BACK_TO_BROM
 	select SPL
 	select SUPPORT_SPL
common/spl/Kconfig.tpl +10 -9
index 22ca7016453..980d6da202a 100644
@@ -106,12 +106,6 @@ config TPL_LDSCRIPT
 	  May be left empty to trigger the Makefile infrastructure to
 	  fall back to the linker-script used for the SPL stage.
 
-config TPL_NEEDS_SEPARATE_STACK
-	bool "TPL needs a separate initial stack-pointer"
-	help
-	  Enable, if the TPL stage should not inherit its initial
-	  stack-pointer from the settings for the SPL stage.
-
 config TPL_POWER
 	bool "Support power drivers"
 	help
@@ -140,11 +134,18 @@ config TPL_MAX_SIZE
 	help
 	  The maximum size (in bytes) of the TPL stage.
 
+config TPL_HAVE_INIT_STACK
+	bool "TPL requires a initial, fixed, stack-pointer location"
+	help
+	  Enable if the TPL phase should not use inherit its initial
+	  stack-pointer from the settings for U-Boot proper, but should set
+	  its own value.
+
 config TPL_STACK
-	hex "Address of the initial stack-pointer for the TPL stage"
-	depends on TPL_NEEDS_SEPARATE_STACK
+	hex "Address of the initial stack-pointer for the TPL phase"
+	depends on TPL_HAVE_INIT_STACK
 	help
-	  The address of the initial stack-pointer for the TPL stage.
+	  The address of the initial stack-pointer for the TPL phase
 	  Usually this will be the (aligned) top-of-stack.
 
 config TPL_READ_ONLY
configs/mk808_defconfig +1 -1
index e47d0b594f3..a1f089a23ea 100644
@@ -48,7 +48,7 @@ CONFIG_SPL_NO_BSS_LIMIT=y
 CONFIG_SPL_SEPARATE_BSS=y
 CONFIG_SPL_FS_EXT4=y
 CONFIG_SYS_MMCSD_FS_BOOT_PARTITION=2
-CONFIG_TPL_NEEDS_SEPARATE_STACK=y
+CONFIG_TPL_HAVE_INIT_STACK=y
 # CONFIG_BOOTM_PLAN9 is not set
 # CONFIG_BOOTM_RTEMS is not set
 # CONFIG_BOOTM_VXWORKS is not set
Signature · 1 line
2.43.0
#2 lore raw

Re: [PATCH v2 01/35] tpl: Rename TPL_NEEDS_SEPARATE_STACK to TPL_HAVE_INIT_STACK

Hi Simon,

Quoted 2 lines · Simon Glass

The most common word for features that make a platform work is to use 'HAVE_xxx'. Rename this option to match.

We already have HAS_CUSTOM_SYS_INIT_SP_ADDR related to the init stack pointer address, maybe the new symbol should be named something similar to that? e.g. HAS_xPL_INIT_SP_ADDR

Quoted 5 lines

Update the help to use the word 'phase' rather than 'stage', since that is the current terminology. Also clarify that, absent this setting, the stack pointer generally comes from the value used by U-Boot proper, rather than SPL.

The last statement is not fully correct, see below.

Quoted 21 lines

Move the option just above TPL_STACK which depends on it.

---

Changes in v2:
- Add new patch to rename TPL_NEEDS_SEPARATE_STACK

 arch/arm/lib/crt0.S            |  2 +-
 arch/arm/lib/crt0_64.S         |  2 +-
 arch/arm/mach-rockchip/Kconfig | 14 +++++++-------
 common/spl/Kconfig.tpl         | 19 ++++++++++---------
 configs/mk808_defconfig        |  2 +-
 5 files changed, 20 insertions(+), 19 deletions(-)
arch/arm/lib/crt0.S +0 -0
index a691d844847..a7e6f50d39a 100644

arch/arm/lib/crt0.S ENTRY(_main) · line 106

Quoted 8 lines
arch/arm/lib/crt0.S +1 -1
@@ -100,7 +100,7 @@ ENTRY(_main)
  * Set up initial C runtime environment and call board_init_f(0).
  */
 
-#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_NEEDS_SEPARATE_STACK)
+#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
 	ldr	r0, =(CONFIG_TPL_STACK)
 #elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_STACK)
 	ldr	r0, =(CONFIG_SPL_STACK)

Here we can see that SPL_STACK is used as the first fallback for XPL_BUILD's.

Quoted 98 lines
arch/arm/lib/crt0_64.S +1 -1
index 32401f544a7..62a0abe1fed 100644
@@ -69,7 +69,7 @@ ENTRY(_main)
 /*
  * Set up initial C runtime environment and call board_init_f(0).
  */
-#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_NEEDS_SEPARATE_STACK)
+#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
 	ldr	x0, =(CONFIG_TPL_STACK)
 #elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_STACK)
 	ldr	x0, =(CONFIG_SPL_STACK)
arch/arm/mach-rockchip/Kconfig +7 -7
index 4d3157b2edd..4c515593718 100644
@@ -9,7 +9,7 @@ config ROCKCHIP_PX30
 	select SPL
 	select TPL
 	select TPL_TINY_FRAMEWORK if TPL
-	select TPL_NEEDS_SEPARATE_STACK if TPL
+	select TPL_HAVE_INIT_STACK if TPL
 	imply SPL_SEPARATE_BSS
 	select SPL_SERIAL
 	select TPL_SERIAL
@@ -106,7 +106,7 @@ config ROCKCHIP_RK322X
 	select TPL
 	select TPL_DM
 	select TPL_OF_LIBFDT
-	select TPL_NEEDS_SEPARATE_STACK if TPL
+	select TPL_HAVE_INIT_STACK if TPL
 	select SPL_DRIVERS_MISC
 	imply ROCKCHIP_COMMON_BOARD
 	imply SPL_SERIAL
@@ -139,7 +139,7 @@ config ROCKCHIP_RK3288
 	imply TPL_DRIVERS_MISC
 	imply TPL_LIBCOMMON_SUPPORT
 	imply TPL_LIBGENERIC_SUPPORT
-	imply TPL_NEEDS_SEPARATE_STACK
+	imply TPL_HAVE_INIT_STACK
 	imply TPL_OF_CONTROL
 	imply TPL_OF_PLATDATA
 	imply TPL_RAM
@@ -197,7 +197,7 @@ config ROCKCHIP_RK3328
 	select SPL
 	select SUPPORT_TPL
 	select TPL
-	select TPL_NEEDS_SEPARATE_STACK if TPL
+	select TPL_HAVE_INIT_STACK if TPL
 	imply ARMV8_CRYPTO
 	imply ARMV8_SET_SMPEN
 	imply MISC
@@ -225,7 +225,7 @@ config ROCKCHIP_RK3368
 	select ARM64
 	select SUPPORT_SPL
 	select SUPPORT_TPL
-	select TPL_NEEDS_SEPARATE_STACK if TPL
+	select TPL_HAVE_INIT_STACK if TPL
 	imply ROCKCHIP_COMMON_BOARD
 	imply SPL_ROCKCHIP_COMMON_BOARD
 	imply SPL_SEPARATE_BSS
@@ -257,7 +257,7 @@ config ROCKCHIP_RK3399
 	select SPL_RAM if SPL
 	select SPL_REGMAP if SPL
 	select SPL_SYSCON if SPL
-	select TPL_NEEDS_SEPARATE_STACK if TPL
+	select TPL_HAVE_INIT_STACK if TPL
 	select SPL_SEPARATE_BSS
 	select CLK
 	select FIT
@@ -392,7 +392,7 @@ config ROCKCHIP_RV1126
 	select SKIP_LOWLEVEL_INIT_ONLY
 	select TPL
 	select SUPPORT_TPL
-	select TPL_NEEDS_SEPARATE_STACK
+	select TPL_HAVE_INIT_STACK
 	select TPL_ROCKCHIP_BACK_TO_BROM
 	select SPL
 	select SUPPORT_SPL
common/spl/Kconfig.tpl +0 -6
index 22ca7016453..980d6da202a 100644
@@ -106,12 +106,6 @@ config TPL_LDSCRIPT
 	  May be left empty to trigger the Makefile infrastructure to
 	  fall back to the linker-script used for the SPL stage.
 
-config TPL_NEEDS_SEPARATE_STACK
-	bool "TPL needs a separate initial stack-pointer"
-	help
-	  Enable, if the TPL stage should not inherit its initial
-	  stack-pointer from the settings for the SPL stage.
-
 config TPL_POWER
 	bool "Support power drivers"
 	help

common/spl/Kconfig.tpl config TPL_MAX_SIZE · line 140

Quoted 7 lines
common/spl/Kconfig.tpl +4 -0
@@ -140,11 +134,18 @@ config TPL_MAX_SIZE
 	help
 	  The maximum size (in bytes) of the TPL stage.
 
+config TPL_HAVE_INIT_STACK
+	bool "TPL requires a initial, fixed, stack-pointer location"
+	help
+	  Enable if the TPL phase should not use inherit its initial

"should not use inherit its initial" does not sound correct.

common/spl/Kconfig.tpl config TPL_MAX_SIZE · line 141

Quoted 1 line
common/spl/Kconfig.tpl +1 -0
+	  stack-pointer from the settings for U-Boot proper, but should set

Here you are changing from SPL to proper, however the SPL address will be used as the fallback (if it is defined) and then SYS_INIT_SP_ADDR.

common/spl/Kconfig.tpl config TPL_MAX_SIZE · line 148

Quoted 10 lines
common/spl/Kconfig.tpl +5 -3
+	  its own value.
+
 config TPL_STACK
-	hex "Address of the initial stack-pointer for the TPL stage"
-	depends on TPL_NEEDS_SEPARATE_STACK
+	hex "Address of the initial stack-pointer for the TPL phase"
+	depends on TPL_HAVE_INIT_STACK
 	help
-	  The address of the initial stack-pointer for the TPL stage.
+	  The address of the initial stack-pointer for the TPL phase

Did you remove the . (period) on purpose?

Regards,
Jonas

Quoted 16 lines
common/spl/Kconfig.tpl +0 -0
 	  Usually this will be the (aligned) top-of-stack.
 
 config TPL_READ_ONLY
configs/mk808_defconfig +1 -1
index e47d0b594f3..a1f089a23ea 100644
@@ -48,7 +48,7 @@ CONFIG_SPL_NO_BSS_LIMIT=y
 CONFIG_SPL_SEPARATE_BSS=y
 CONFIG_SPL_FS_EXT4=y
 CONFIG_SYS_MMCSD_FS_BOOT_PARTITION=2
-CONFIG_TPL_NEEDS_SEPARATE_STACK=y
+CONFIG_TPL_HAVE_INIT_STACK=y
 # CONFIG_BOOTM_PLAN9 is not set
 # CONFIG_BOOTM_RTEMS is not set
 # CONFIG_BOOTM_VXWORKS is not set
#3 lore raw

Re: [PATCH v2 01/35] tpl: Rename TPL_NEEDS_SEPARATE_STACK to TPL_HAVE_INIT_STACK

Hi Jonas,

Quoted 10 lines · Jonas Karlman

Hi Simon,

Quoted 2 lines · Simon Glass

The most common word for features that make a platform work is to use 'HAVE_xxx'. Rename this option to match.

We already have HAS_CUSTOM_SYS_INIT_SP_ADDR related to the init stack pointer address, maybe the new symbol should be named something similar to that? e.g. HAS_xPL_INIT_SP_ADDR

That would be quite confusing, since we still need SYS_INIT_SP_ADDR that option to work.

The name would have to be xPL_HAS_SP_INIT_SP_ADDR to fit with the naming convention and allow CONFIG_IS_ENABLED() and avoid more confusion. Plus, SYS_INIT_SP_ADDR is actually a fallback for when the xPL builds don't provide their own address.

So I think this needs to be separate, particularly as Tom is talking of splitting the deconfig files, at which point we wouldn't be able to make xPL use SYS_INIT_SP_ADDR as a default.

Quoted 33 lines
Quoted 6 lines

Update the help to use the word 'phase' rather than 'stage', since that is the current terminology. Also clarify that, absent this setting, the stack pointer generally comes from the value used by U-Boot proper, rather than SPL.

The last statement is not fully correct, see below.

Quoted 24 lines

Move the option just above TPL_STACK which depends on it.

---

Changes in v2:
- Add new patch to rename TPL_NEEDS_SEPARATE_STACK

 arch/arm/lib/crt0.S            |  2 +-
 arch/arm/lib/crt0_64.S         |  2 +-
 arch/arm/mach-rockchip/Kconfig | 14 +++++++-------
 common/spl/Kconfig.tpl         | 19 ++++++++++---------
 configs/mk808_defconfig        |  2 +-
 5 files changed, 20 insertions(+), 19 deletions(-)
arch/arm/lib/crt0.S +0 -0
index a691d844847..a7e6f50d39a 100644
@@ -100,7 +100,7 @@ ENTRY(_main)
  * Set up initial C runtime environment and call board_init_f(0).
  */
 
Quoted 8 lines

arch/arm/lib/crt0.S ENTRY(_main) · line 106

Quoted 5 lines
arch/arm/lib/crt0.S +1 -1
-#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_NEEDS_SEPARATE_STACK)
+#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
      ldr     r0, =(CONFIG_TPL_STACK)
 #elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_STACK)
      ldr     r0, =(CONFIG_SPL_STACK)

Here we can see that SPL_STACK is used as the first fallback for XPL_BUILD's.

Oh dear. I believe that is unintended, but I'm not sure which way to take it. For now I'll update the comment.

Quoted 102 lines
Quoted 102 lines
arch/arm/lib/crt0_64.S +1 -1
index 32401f544a7..62a0abe1fed 100644
@@ -69,7 +69,7 @@ ENTRY(_main)
 /*
  * Set up initial C runtime environment and call board_init_f(0).
  */
-#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_NEEDS_SEPARATE_STACK)
+#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
      ldr     x0, =(CONFIG_TPL_STACK)
 #elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_STACK)
      ldr     x0, =(CONFIG_SPL_STACK)
arch/arm/mach-rockchip/Kconfig +7 -7
index 4d3157b2edd..4c515593718 100644
@@ -9,7 +9,7 @@ config ROCKCHIP_PX30
      select SPL
      select TPL
      select TPL_TINY_FRAMEWORK if TPL
-     select TPL_NEEDS_SEPARATE_STACK if TPL
+     select TPL_HAVE_INIT_STACK if TPL
      imply SPL_SEPARATE_BSS
      select SPL_SERIAL
      select TPL_SERIAL
@@ -106,7 +106,7 @@ config ROCKCHIP_RK322X
      select TPL
      select TPL_DM
      select TPL_OF_LIBFDT
-     select TPL_NEEDS_SEPARATE_STACK if TPL
+     select TPL_HAVE_INIT_STACK if TPL
      select SPL_DRIVERS_MISC
      imply ROCKCHIP_COMMON_BOARD
      imply SPL_SERIAL
@@ -139,7 +139,7 @@ config ROCKCHIP_RK3288
      imply TPL_DRIVERS_MISC
      imply TPL_LIBCOMMON_SUPPORT
      imply TPL_LIBGENERIC_SUPPORT
-     imply TPL_NEEDS_SEPARATE_STACK
+     imply TPL_HAVE_INIT_STACK
      imply TPL_OF_CONTROL
      imply TPL_OF_PLATDATA
      imply TPL_RAM
@@ -197,7 +197,7 @@ config ROCKCHIP_RK3328
      select SPL
      select SUPPORT_TPL
      select TPL
-     select TPL_NEEDS_SEPARATE_STACK if TPL
+     select TPL_HAVE_INIT_STACK if TPL
      imply ARMV8_CRYPTO
      imply ARMV8_SET_SMPEN
      imply MISC
@@ -225,7 +225,7 @@ config ROCKCHIP_RK3368
      select ARM64
      select SUPPORT_SPL
      select SUPPORT_TPL
-     select TPL_NEEDS_SEPARATE_STACK if TPL
+     select TPL_HAVE_INIT_STACK if TPL
      imply ROCKCHIP_COMMON_BOARD
      imply SPL_ROCKCHIP_COMMON_BOARD
      imply SPL_SEPARATE_BSS
@@ -257,7 +257,7 @@ config ROCKCHIP_RK3399
      select SPL_RAM if SPL
      select SPL_REGMAP if SPL
      select SPL_SYSCON if SPL
-     select TPL_NEEDS_SEPARATE_STACK if TPL
+     select TPL_HAVE_INIT_STACK if TPL
      select SPL_SEPARATE_BSS
      select CLK
      select FIT
@@ -392,7 +392,7 @@ config ROCKCHIP_RV1126
      select SKIP_LOWLEVEL_INIT_ONLY
      select TPL
      select SUPPORT_TPL
-     select TPL_NEEDS_SEPARATE_STACK
+     select TPL_HAVE_INIT_STACK
      select TPL_ROCKCHIP_BACK_TO_BROM
      select SPL
      select SUPPORT_SPL
common/spl/Kconfig.tpl +0 -6
index 22ca7016453..980d6da202a 100644
@@ -106,12 +106,6 @@ config TPL_LDSCRIPT
        May be left empty to trigger the Makefile infrastructure to
        fall back to the linker-script used for the SPL stage.
 
-config TPL_NEEDS_SEPARATE_STACK
-     bool "TPL needs a separate initial stack-pointer"
-     help
-       Enable, if the TPL stage should not inherit its initial
-       stack-pointer from the settings for the SPL stage.
-
 config TPL_POWER
      bool "Support power drivers"
      help
@@ -140,11 +134,18 @@ config TPL_MAX_SIZE
      help
        The maximum size (in bytes) of the TPL stage.
 
Quoted 6 lines

common/spl/Kconfig.tpl config TPL_MAX_SIZE · line 140

Quoted 4 lines
common/spl/Kconfig.tpl +4 -0
+config TPL_HAVE_INIT_STACK
+     bool "TPL requires a initial, fixed, stack-pointer location"
+     help
+       Enable if the TPL phase should not use inherit its initial

"should not use inherit its initial" does not sound correct.

Fixed

Quoted 5 lines

common/spl/Kconfig.tpl config TPL_MAX_SIZE · line 141

Quoted 2 lines
common/spl/Kconfig.tpl +1 -0
+       stack-pointer from the settings for U-Boot proper, but should set

Here you are changing from SPL to proper, however the SPL address will be used as the fallback (if it is defined) and then SYS_INIT_SP_ADDR.

OK, I'll update that.

Quoted 12 lines

common/spl/Kconfig.tpl config TPL_MAX_SIZE · line 148

Quoted 11 lines
common/spl/Kconfig.tpl +5 -3
+       its own value.
+
 config TPL_STACK
-     hex "Address of the initial stack-pointer for the TPL stage"
-     depends on TPL_NEEDS_SEPARATE_STACK
+     hex "Address of the initial stack-pointer for the TPL phase"
+     depends on TPL_HAVE_INIT_STACK
      help
-       The address of the initial stack-pointer for the TPL stage.
+       The address of the initial stack-pointer for the TPL phase
Quoted 1 line

Did you remove the . (period) on purpose?

Yes, as it is not a sentence

Quoted 6 lines

Regards,
Jonas

Quoted 2 lines
common/spl/Kconfig.tpl +0 -0
        Usually this will be the (aligned) top-of-stack.
 
Quoted 15 lines
Quoted 6 lines
common/spl/Kconfig.tpl +0 -0
 config TPL_READ_ONLY
configs/mk808_defconfig +0 -0
index e47d0b594f3..a1f089a23ea 100644

configs/mk808_defconfig CONFIG_SPL_NO_BSS_LIMIT=y · line 54

Quoted 8 lines
configs/mk808_defconfig +1 -1
@@ -48,7 +48,7 @@ CONFIG_SPL_NO_BSS_LIMIT=y
 CONFIG_SPL_SEPARATE_BSS=y
 CONFIG_SPL_FS_EXT4=y
 CONFIG_SYS_MMCSD_FS_BOOT_PARTITION=2
-CONFIG_TPL_NEEDS_SEPARATE_STACK=y
+CONFIG_TPL_HAVE_INIT_STACK=y
 # CONFIG_BOOTM_PLAN9 is not set
 # CONFIG_BOOTM_RTEMS is not set
 # CONFIG_BOOTM_VXWORKS is not set

Regards,
Simon

#4 lore raw

PATCH v2 2/35 spl: Add an SPL_HAVE_INIT_STACK option

In reply to Simon Glass

At present there is a hex value SPL_STACK which both determines whether SPL has its own initial stack and the hex value of that stack.

Split off the former into SPL_HAVE_INIT_STACK with SPL_STACK depending on that and only providing the latter.

---

Changes in v2:
- Add new patch with an SPL_HAVE_INIT_STACK option

 arch/arm/cpu/armv7/lowlevel_init.S            |  2 +-
 arch/arm/cpu/armv7/start.S                    |  2 +-
 arch/arm/lib/crt0.S                           |  2 +-
 arch/arm/lib/crt0_64.S                        |  2 +-
 arch/riscv/cpu/start.S                        |  2 +-
 common/spl/Kconfig                            | 28 +++++++++++++++----
 configs/alt_defconfig                         |  1 +
 configs/apalis-tk1_defconfig                  |  1 +
 configs/apalis_t30_defconfig                  |  1 +
 configs/axm_defconfig                         |  1 +
 configs/beaver_defconfig                      |  1 +
 configs/bitmain_antminer_s9_defconfig         |  1 +
 configs/capricorn_cxg3_defconfig              |  1 +
 configs/cardhu_defconfig                      |  1 +
 configs/cei-tk1-som_defconfig                 |  1 +
 configs/cgtqmx8_defconfig                     |  1 +
 configs/chromebit_mickey_defconfig            |  1 +
 configs/chromebook_bob_defconfig              |  1 +
 configs/chromebook_jerry_defconfig            |  1 +
 configs/chromebook_kevin_defconfig            |  1 +
 configs/chromebook_minnie_defconfig           |  1 +
 configs/chromebook_speedy_defconfig           |  1 +
 configs/ci20_mmc_defconfig                    |  1 +
 configs/clearfog_defconfig                    |  1 +
 configs/clearfog_sata_defconfig               |  1 +
 configs/clearfog_spi_defconfig                |  1 +
 configs/colibri_t20_defconfig                 |  1 +
 configs/colibri_t30_defconfig                 |  1 +
 configs/controlcenterdc_defconfig             |  1 +
 configs/corvus_defconfig                      |  1 +
 configs/da850evm_defconfig                    |  1 +
 configs/da850evm_nand_defconfig               |  1 +
 configs/dalmore_defconfig                     |  1 +
 configs/db-88f6720_defconfig                  |  1 +
 configs/db-88f6820-amc_defconfig              |  1 +
 configs/db-88f6820-amc_nand_defconfig         |  1 +
 configs/db-88f6820-gp_defconfig               |  1 +
 configs/db-mv784mp-gp_defconfig               |  1 +
 configs/ds116_defconfig                       |  1 +
 configs/ds414_defconfig                       |  1 +
 configs/endeavoru_defconfig                   |  1 +
 configs/evb-px5_defconfig                     |  1 +
 configs/evb-rk3036_defconfig                  |  1 +
 configs/evb-rk3288_defconfig                  |  1 +
 .../gardena-smart-gateway-at91sam_defconfig   |  1 +
 configs/gose_defconfig                        |  1 +
 configs/grouper_defconfig                     |  1 +
 configs/harmony_defconfig                     |  1 +
 configs/helios4_defconfig                     |  1 +
 configs/ideapad-yoga-11_defconfig             |  1 +
 configs/imx28_xea_defconfig                   |  1 +
 configs/imx8mm-cl-iot-gate-optee_defconfig    |  1 +
 configs/imx8mm-cl-iot-gate_defconfig          |  1 +
 configs/imx8mm-icore-mx8mm-ctouch2_defconfig  |  1 +
 configs/imx8mm-icore-mx8mm-edimm2.2_defconfig |  1 +
 configs/imx8mm-mx8menlo_defconfig             |  1 +
 configs/imx8mm-phygate-tauri-l_defconfig      |  1 +
 configs/imx8mm_beacon_defconfig               |  1 +
 configs/imx8mm_beacon_fspi_defconfig          |  1 +
 configs/imx8mm_data_modul_edm_sbc_defconfig   |  1 +
 configs/imx8mm_evk_defconfig                  |  1 +
 configs/imx8mm_evk_fspi_defconfig             |  1 +
 configs/imx8mm_phg_defconfig                  |  1 +
 configs/imx8mm_venice_defconfig               |  1 +
 configs/imx8mn_beacon_2g_defconfig            |  1 +
 configs/imx8mn_beacon_defconfig               |  1 +
 configs/imx8mn_beacon_fspi_defconfig          |  1 +
 configs/imx8mn_bsh_smm_s2_defconfig           |  1 +
 configs/imx8mn_bsh_smm_s2pro_defconfig        |  1 +
 configs/imx8mn_ddr4_evk_defconfig             |  1 +
 configs/imx8mn_evk_defconfig                  |  1 +
 configs/imx8mn_var_som_defconfig              |  1 +
 configs/imx8mn_venice_defconfig               |  1 +
 configs/imx8mp-icore-mx8mp-edimm2.2_defconfig |  1 +
 configs/imx8mp_beacon_defconfig               |  1 +
 configs/imx8mp_data_modul_edm_sbc_defconfig   |  1 +
 configs/imx8mp_debix_model_a_defconfig        |  1 +
 configs/imx8mp_dhsom.config                   |  1 +
 configs/imx8mp_evk_defconfig                  |  1 +
 configs/imx8mp_navqp_defconfig                |  1 +
 configs/imx8mp_rsb3720a1_4G_defconfig         |  1 +
 configs/imx8mp_rsb3720a1_6G_defconfig         |  1 +
 configs/imx8mp_venice_defconfig               |  1 +
 configs/imx8mq_cm_defconfig                   |  1 +
 configs/imx8mq_evk_defconfig                  |  1 +
 configs/imx8mq_phanbell_defconfig             |  1 +
 configs/imx8mq_reform2_defconfig              |  1 +
 configs/imx8qm_dmsse20a1_defconfig            |  1 +
 configs/imx8qm_mek_defconfig                  |  1 +
 configs/imx8qxp_mek_defconfig                 |  1 +
 configs/imx8ulp_evk_defconfig                 |  1 +
 configs/imx93-phycore_defconfig               |  1 +
 configs/imx93_11x11_evk_defconfig             |  1 +
 configs/imx93_9x9_qsb_defconfig               |  1 +
 configs/imx93_9x9_qsb_inline_ecc_defconfig    |  1 +
 configs/imx93_var_som_defconfig               |  1 +
 configs/jetson-tk1_defconfig                  |  1 +
 configs/k2e_evm_defconfig                     |  1 +
 configs/k2g_evm_defconfig                     |  1 +
 configs/k2hk_evm_defconfig                    |  1 +
 configs/k2l_evm_defconfig                     |  1 +
 configs/koelsch_defconfig                     |  1 +
 configs/kontron-sl-mx8mm_defconfig            |  1 +
 configs/kontron_pitx_imx8m_defconfig          |  1 +
 configs/kontron_sl28_defconfig                |  1 +
 configs/kylin-rk3036_defconfig                |  1 +
 configs/lager_defconfig                       |  1 +
 configs/librem5_defconfig                     |  1 +
 configs/ls1021aiot_sdcard_defconfig           |  1 +
 configs/ls1021aqds_nand_defconfig             |  1 +
 configs/ls1021aqds_sdcard_ifc_defconfig       |  1 +
 configs/ls1021aqds_sdcard_qspi_defconfig      |  1 +
 configs/ls1021atsn_sdcard_defconfig           |  1 +
 ...s1021atwr_sdcard_ifc_SECURE_BOOT_defconfig |  1 +
 configs/ls1021atwr_sdcard_ifc_defconfig       |  1 +
 configs/ls1021atwr_sdcard_qspi_defconfig      |  1 +
 configs/ls2080aqds_nand_defconfig             |  1 +
 configs/ls2080ardb_nand_defconfig             |  1 +
 configs/m53menlo_defconfig                    |  1 +
 configs/maxbcm_defconfig                      |  1 +
 configs/medcom-wide_defconfig                 |  1 +
 configs/microblaze-generic_defconfig          |  1 +
 configs/mk808_defconfig                       |  1 +
 configs/msc_sm2s_imx8mp_defconfig             |  1 +
 configs/mt7629_rfb_defconfig                  |  1 +
 configs/n2350_defconfig                       |  1 +
 configs/nyan-big_defconfig                    |  1 +
 configs/omapl138_lcdk_defconfig               |  1 +
 configs/openpiton_riscv64_spl_defconfig       |  1 +
 configs/paz00_defconfig                       |  1 +
 configs/phycore-imx8mm_defconfig              |  1 +
 configs/phycore-imx8mp_defconfig              |  1 +
 configs/phycore-rk3288_defconfig              |  1 +
 configs/pico-imx8mq_defconfig                 |  1 +
 configs/plutux_defconfig                      |  1 +
 configs/popmetal-rk3288_defconfig             |  1 +
 configs/porter_defconfig                      |  1 +
 configs/qc750_defconfig                       |  1 +
 configs/r8a77970_eagle_defconfig              |  1 +
 configs/r8a77970_v3msk_defconfig              |  1 +
 configs/r8a77980_condor_defconfig             |  1 +
 configs/r8a77980_v3hsk_defconfig              |  1 +
 configs/r8a77990_ebisu_defconfig              |  1 +
 configs/r8a77995_draak_defconfig              |  1 +
 configs/rcar3_salvator-x_defconfig            |  1 +
 configs/rcar3_ulcb_defconfig                  |  1 +
 configs/rock-pi-n8-rk3288_defconfig           |  1 +
 configs/rock2_defconfig                       |  1 +
 configs/rock_defconfig                        |  1 +
 configs/sama5d27_giantboard_defconfig         |  1 +
 configs/sama5d27_som1_ek_mmc1_defconfig       |  1 +
 configs/sama5d27_som1_ek_mmc_defconfig        |  1 +
 configs/sama5d27_som1_ek_qspiflash_defconfig  |  1 +
 configs/sama5d27_wlsom1_ek_mmc_defconfig      |  1 +
 .../sama5d27_wlsom1_ek_qspiflash_defconfig    |  1 +
 configs/sama5d2_icp_mmc_defconfig             |  1 +
 configs/sama5d2_xplained_emmc_defconfig       |  1 +
 configs/sama5d2_xplained_mmc_defconfig        |  1 +
 configs/sama5d2_xplained_qspiflash_defconfig  |  1 +
 configs/sama5d2_xplained_spiflash_defconfig   |  1 +
 configs/sama5d3_xplained_mmc_defconfig        |  1 +
 configs/sama5d3_xplained_nandflash_defconfig  |  1 +
 configs/sama5d3xek_mmc_defconfig              |  1 +
 configs/sama5d3xek_nandflash_defconfig        |  1 +
 configs/sama5d3xek_spiflash_defconfig         |  1 +
 configs/sama5d4_xplained_mmc_defconfig        |  1 +
 configs/sama5d4_xplained_nandflash_defconfig  |  1 +
 configs/sama5d4_xplained_spiflash_defconfig   |  1 +
 configs/sama5d4ek_mmc_defconfig               |  1 +
 configs/sama5d4ek_nandflash_defconfig         |  1 +
 configs/sama5d4ek_spiflash_defconfig          |  1 +
 configs/seaboard_defconfig                    |  1 +
 configs/sifive_unleashed_defconfig            |  1 +
 configs/sifive_unmatched_defconfig            |  1 +
 configs/silinux_ek874_defconfig               |  1 +
 configs/silk_defconfig                        |  1 +
 configs/smartweb_defconfig                    |  1 +
 configs/socfpga_agilex5_defconfig             |  1 +
 configs/socfpga_agilex_atf_defconfig          |  1 +
 configs/socfpga_agilex_defconfig              |  1 +
 configs/socfpga_agilex_vab_defconfig          |  1 +
 configs/socfpga_arria10_defconfig             |  1 +
 configs/socfpga_arria5_defconfig              |  1 +
 configs/socfpga_cyclone5_defconfig            |  1 +
 configs/socfpga_dbm_soc1_defconfig            |  1 +
 configs/socfpga_de0_nano_soc_defconfig        |  1 +
 configs/socfpga_de10_nano_defconfig           |  1 +
 configs/socfpga_de10_standard_defconfig       |  1 +
 configs/socfpga_de1_soc_defconfig             |  1 +
 configs/socfpga_is1_defconfig                 |  1 +
 configs/socfpga_mcvevk_defconfig              |  1 +
 configs/socfpga_n5x_atf_defconfig             |  1 +
 configs/socfpga_n5x_defconfig                 |  1 +
 configs/socfpga_n5x_vab_defconfig             |  1 +
 configs/socfpga_secu1_defconfig               |  1 +
 configs/socfpga_sockit_defconfig              |  1 +
 configs/socfpga_socrates_defconfig            |  1 +
 configs/socfpga_sr1500_defconfig              |  1 +
 configs/socfpga_stratix10_atf_defconfig       |  1 +
 configs/socfpga_stratix10_defconfig           |  1 +
 configs/socfpga_vining_fpga_defconfig         |  1 +
 configs/starfive_visionfive2_defconfig        |  1 +
 ...stm32mp15-icore-stm32mp1-ctouch2_defconfig |  1 +
 ...tm32mp15-icore-stm32mp1-edimm2.2_defconfig |  1 +
 ...-microgea-stm32mp1-microdev2-of7_defconfig |  1 +
 ...mp15-microgea-stm32mp1-microdev2_defconfig |  1 +
 configs/stm32mp15_basic_defconfig             |  1 +
 configs/stm32mp15_dhsom.config                |  1 +
 configs/stout_defconfig                       |  1 +
 configs/surface-rt_defconfig                  |  1 +
 configs/syzygy_hub_defconfig                  |  1 +
 configs/taurus_defconfig                      |  1 +
 configs/tec-ng_defconfig                      |  1 +
 configs/tec_defconfig                         |  1 +
 configs/theadorable_debug_defconfig           |  1 +
 configs/topic_miami_defconfig                 |  1 +
 configs/topic_miamilite_defconfig             |  1 +
 configs/topic_miamiplus_defconfig             |  1 +
 configs/transformer_t20_defconfig             |  1 +
 configs/transformer_t30_defconfig             |  1 +
 configs/trimslice_defconfig                   |  1 +
 configs/turris_omnia_defconfig                |  1 +
 configs/uniphier_ld4_sld8_defconfig           |  1 +
 configs/uniphier_v7_defconfig                 |  1 +
 configs/venice2_defconfig                     |  1 +
 configs/ventana_defconfig                     |  1 +
 configs/verdin-imx8mm_defconfig               |  1 +
 configs/verdin-imx8mp_defconfig               |  1 +
 configs/vyasa-rk3288_defconfig                |  1 +
 configs/work_92105_defconfig                  |  1 +
 configs/x3_t30_defconfig                      |  1 +
 configs/x530_defconfig                        |  1 +
 configs/xilinx_mbv32_defconfig                |  1 +
 configs/xilinx_mbv32_smode_defconfig          |  1 +
 configs/xilinx_mbv64_defconfig                |  1 +
 configs/xilinx_mbv64_smode_defconfig          |  1 +
 configs/xilinx_zynq_virt_defconfig            |  1 +
 configs/xilinx_zynqmp_kria_defconfig          |  1 +
 configs/xilinx_zynqmp_mini_emmc0_defconfig    |  1 +
 configs/xilinx_zynqmp_mini_emmc1_defconfig    |  1 +
 configs/xilinx_zynqmp_mini_qspi_defconfig     |  1 +
 configs/xilinx_zynqmp_virt_defconfig          |  1 +
 configs/zynq_cse_nand_defconfig               |  1 +
 configs/zynq_cse_nor_defconfig                |  1 +
 configs/zynq_cse_qspi_defconfig               |  1 +
 245 files changed, 267 insertions(+), 10 deletions(-)
arch/arm/cpu/armv7/lowlevel_init.S +1 -1
index a6c844b7e3d..c2a0fe061a3 100644
@@ -26,7 +26,7 @@ WEAK(lowlevel_init)
 	/*
 	 * Setup a temporary stack. Global data is not available yet.
 	 */
-#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_STACK)
+#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
 	ldr	sp, =CONFIG_SPL_STACK
 #else
 	ldr	sp, =SYS_INIT_SP_ADDR
arch/arm/cpu/armv7/start.S +1 -1
index b63481b43ca..3394db46953 100644
@@ -279,7 +279,7 @@ ENTRY(cpu_init_cp15)
 	orr	r2, r4, r2		@ r2 has combined CPU variant + revision
 
 /* Early stack for ERRATA that needs into call C code */
-#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_STACK)
+#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
 	ldr	r0, =(CONFIG_SPL_STACK)
 #else
 	ldr	r0, =(SYS_INIT_SP_ADDR)
arch/arm/lib/crt0.S +1 -1
index a7e6f50d39a..007e89407a8 100644
@@ -102,7 +102,7 @@ ENTRY(_main)
 
 #if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
 	ldr	r0, =(CONFIG_TPL_STACK)
-#elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_STACK)
+#elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
 	ldr	r0, =(CONFIG_SPL_STACK)
 #else
 	ldr	r0, =(SYS_INIT_SP_ADDR)
arch/arm/lib/crt0_64.S +1 -1
index 62a0abe1fed..1b6782b06ed 100644
@@ -71,7 +71,7 @@ ENTRY(_main)
  */
 #if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
 	ldr	x0, =(CONFIG_TPL_STACK)
-#elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_STACK)
+#elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
 	ldr	x0, =(CONFIG_SPL_STACK)
 #elif defined(CONFIG_INIT_SP_RELATIVE)
 #if CONFIG_POSITION_INDEPENDENT
arch/riscv/cpu/start.S +1 -1
index 3f78932aa9d..c8526dd82fd 100644
@@ -90,7 +90,7 @@ _start:
  * Set stackpointer in internal/ex RAM to call board_init_f
  */
 call_board_init_f:
-#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_STACK)
+#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
 	li	t0, CONFIG_SPL_STACK
 #else
 	li	t0, SYS_INIT_SP_ADDR
common/spl/Kconfig +23 -5
index a250bde779f..85566385c21 100644
@@ -387,11 +387,29 @@ config SPL_SHARES_INIT_SP_ADDR
 	  both SPL and U-Boot itself.  If you need to specify a different address
 	  however, say N here and then set a different value in CONFIG_SPL_STACK.
 
-config SPL_STACK
-	hex "Initial stack pointer location"
+config SPL_HAVE_INIT_STACK
+	bool "SPL requires a initial, fixed, stack-pointer location"
 	depends on (ARM || ARCH_JZ47XX || MICROBLAZE || RISCV) && \
 		SPL_FRAMEWORK || ROCKCHIP_RK3036
 	depends on !SPL_SHARES_INIT_SP_ADDR
+	default y if ARCH_MX7
+	default y if ARCH_MX6 && MX6_OCRAM_256KB
+	default y if ARCH_MX6 && !MX6_OCRAM_256KB
+	default y if MACH_SUN50I_H6 || MACH_SUN50I_H616 || MACH_SUN8I_R528
+	default y if MACH_SUN50I || MACH_SUN50I_H5
+	default y if MACH_SUN9I
+	default y if ARCH_SUNXI
+	default y if ARCH_SC5XX && (SC59X_64 || SC59X)
+	default y if ARCH_SC5XX && SC58X
+	default y if ARCH_SC5XX && SC57X
+	help
+	  Enable if the SPL phase should not use inherit its initial
+	  stack-pointer from the settings for U-Boot proper, but should set
+	  its own value.
+
+config SPL_STACK
+	hex "Address of the initial stack-pointer for the SPL phase"
+	depends on SPL_HAVE_INIT_STACK
 	default 0x946bb8 if ARCH_MX7
 	default 0x93ffb8 if ARCH_MX6 && MX6_OCRAM_256KB
 	default 0x91ffb8 if ARCH_MX6 && !MX6_OCRAM_256KB
@@ -401,9 +419,9 @@ config SPL_STACK
 	default 0x54000 if MACH_SUN50I || MACH_SUN50I_H5
 	default 0x18000 if MACH_SUN9I
 	default 0x8000 if ARCH_SUNXI
-	default 0x200E4000 if ARCH_SC5XX && (SC59X_64 || SC59X)
-	default 0x200B0000 if ARCH_SC5XX && SC58X
-	default 0x200D0000 if ARCH_SC5XX && SC57X
+	default 0x200e4000 if ARCH_SC5XX && (SC59X_64 || SC59X)
+	default 0x200b0000 if ARCH_SC5XX && SC58X
+	default 0x200d0000 if ARCH_SC5XX && SC57X
 	help
 	  Address of the start of the stack SPL will use before SDRAM is
 	  initialized.
configs/alt_defconfig +1 -0
index 488115d9a5c..bbe4bd0272d 100644
@@ -14,6 +14,7 @@ CONFIG_ARCH_RENESAS_BOARD_STRING="Alt"
 CONFIG_R8A7794=y
 CONFIG_TARGET_ALT=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6340000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x2000
 CONFIG_SPL=y
configs/apalis-tk1_defconfig +1 -0
index ef982f70193..3012ec2d888 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFDE00
 CONFIG_DEFAULT_DEVICE_TREE="tegra124-apalis"
 CONFIG_OF_LIBFDT_OVERLAY=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x81000000
configs/apalis_t30_defconfig +1 -0
index 3143566c2c7..521f5fecda2 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFDE00
 CONFIG_DEFAULT_DEVICE_TREE="tegra30-apalis"
 CONFIG_OF_LIBFDT_OVERLAY=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x81000000
configs/axm_defconfig +1 -0
index 7fd9e4046f2..d0b5830f81f 100644
@@ -19,6 +19,7 @@ CONFIG_SPL_LDSCRIPT="arch/arm/cpu/u-boot-spl.lds"
 CONFIG_ENV_OFFSET=0x100000
 CONFIG_SPL_DM_SPI=y
 CONFIG_DEFAULT_DEVICE_TREE="at91sam9g20-taurus"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x304000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/beaver_defconfig +1 -0
index 71037ee7474..3e944e8aec3 100644
@@ -9,6 +9,7 @@ CONFIG_SF_DEFAULT_SPEED=24000000
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFE000
 CONFIG_DEFAULT_DEVICE_TREE="tegra30-beaver"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x81000000
configs/bitmain_antminer_s9_defconfig +1 -0
index afff2d54f2c..2a3e7446d48 100644
@@ -11,6 +11,7 @@ CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="bitmain-antminer-s9"
 CONFIG_SPL_STACK_R_ADDR=0x200000
 CONFIG_SYS_BOOTCOUNT_ADDR=0xEFFFFF0
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffe00
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0x100000
configs/capricorn_cxg3_defconfig +1 -0
index 276445528a9..2d208702a33 100644
@@ -18,6 +18,7 @@ CONFIG_TARGET_CAPRICORN=y
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x13e000
 CONFIG_SPL_TEXT_BASE=0x100000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/cardhu_defconfig +1 -0
index 57978de66e1..c3434648688 100644
@@ -9,6 +9,7 @@ CONFIG_SF_DEFAULT_SPEED=24000000
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFE000
 CONFIG_DEFAULT_DEVICE_TREE="tegra30-cardhu"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x81000000
configs/cei-tk1-som_defconfig +1 -0
index d2778fbcd03..5e2c0f9e32f 100644
@@ -9,6 +9,7 @@ CONFIG_SF_DEFAULT_SPEED=24000000
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFE000
 CONFIG_DEFAULT_DEVICE_TREE="tegra124-cei-tk1-som"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x81000000
configs/cgtqmx8_defconfig +1 -0
index 37ae957db03..73c6f986d48 100644
@@ -16,6 +16,7 @@ CONFIG_TARGET_CONGA_QMX8=y
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x13e000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0x128000
configs/chromebit_mickey_defconfig +1 -0
index 874f266dad1..d834c1886a5 100644
@@ -15,6 +15,7 @@ CONFIG_ROCKCHIP_RK3288=y
 # CONFIG_SPL_MMC is not set
 CONFIG_TARGET_CHROMEBIT_MICKEY=y
 CONFIG_SPL_STACK_R_ADDR=0x80000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xff718000
 CONFIG_SPL_TEXT_BASE=0xff704000
 CONFIG_SPL_STACK_R=y
configs/chromebook_bob_defconfig +1 -0
index 993d21411fd..52b40903e3f 100644
@@ -16,6 +16,7 @@ CONFIG_ROCKCHIP_RK3399=y
 CONFIG_ROCKCHIP_BOOT_MODE_REG=0
 CONFIG_ROCKCHIP_SPL_RESERVE_IRAM=0x4000
 # CONFIG_SPL_MMC is not set
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xff8effff
 CONFIG_SPL_TEXT_BASE=0xff8c2000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/chromebook_jerry_defconfig +1 -0
index f40b8e84e39..f4b9caeb34f 100644
@@ -14,6 +14,7 @@ CONFIG_SYS_MONITOR_LEN=614400
 CONFIG_ROCKCHIP_RK3288=y
 # CONFIG_SPL_MMC is not set
 CONFIG_SPL_STACK_R_ADDR=0x80000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xff718000
 CONFIG_SPL_TEXT_BASE=0xff704000
 CONFIG_SPL_STACK_R=y
configs/chromebook_kevin_defconfig +1 -0
index 4416bd0a0e6..aff097624ef 100644
@@ -17,6 +17,7 @@ CONFIG_ROCKCHIP_BOOT_MODE_REG=0
 CONFIG_ROCKCHIP_SPL_RESERVE_IRAM=0x4000
 # CONFIG_SPL_MMC is not set
 CONFIG_TARGET_CHROMEBOOK_KEVIN=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xff8effff
 CONFIG_SPL_TEXT_BASE=0xff8c2000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/chromebook_minnie_defconfig +1 -0
index 2f125ba12ad..3a0be3078ab 100644
@@ -15,6 +15,7 @@ CONFIG_ROCKCHIP_RK3288=y
 # CONFIG_SPL_MMC is not set
 CONFIG_TARGET_CHROMEBOOK_MINNIE=y
 CONFIG_SPL_STACK_R_ADDR=0x80000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xff718000
 CONFIG_SPL_TEXT_BASE=0xff704000
 CONFIG_SPL_STACK_R=y
configs/chromebook_speedy_defconfig +1 -0
index c19b0905d5c..78ab62c3392 100644
@@ -15,6 +15,7 @@ CONFIG_ROCKCHIP_RK3288=y
 # CONFIG_SPL_MMC is not set
 CONFIG_TARGET_CHROMEBOOK_SPEEDY=y
 CONFIG_SPL_STACK_R_ADDR=0x80000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xff718000
 CONFIG_SPL_TEXT_BASE=0xff704000
 CONFIG_SPL_STACK_R=y
configs/ci20_mmc_defconfig +1 -0
index 2d094bd6e90..eeb430eb80a 100644
@@ -10,6 +10,7 @@ CONFIG_ENV_OFFSET=0x83800
 CONFIG_DEFAULT_DEVICE_TREE="ci20"
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xf4008000
 CONFIG_SPL_TEXT_BASE=0xf4000a00
 CONFIG_SPL_BSS_START_ADDR=0xf4004000
configs/clearfog_defconfig +1 -0
index 6f6597c5331..c4a7ad66d69 100644
@@ -12,6 +12,7 @@ CONFIG_TARGET_CLEARFOG=y
 CONFIG_MVEBU_SPL_BOOT_DEVICE_MMC=y
 CONFIG_DEFAULT_DEVICE_TREE="armada-388-clearfog"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40000030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/clearfog_sata_defconfig +1 -0
index 491a27321f9..b6ad150cb82 100644
@@ -12,6 +12,7 @@ CONFIG_TARGET_CLEARFOG=y
 CONFIG_MVEBU_SPL_BOOT_DEVICE_SATA=y
 CONFIG_DEFAULT_DEVICE_TREE="armada-388-clearfog"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40000030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/clearfog_spi_defconfig +1 -0
index d3de1657c09..7c7294ec080 100644
@@ -12,6 +12,7 @@ CONFIG_TARGET_CLEARFOG=y
 CONFIG_ENV_SECT_SIZE=0x10000
 CONFIG_DEFAULT_DEVICE_TREE="armada-388-clearfog"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40000030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/colibri_t20_defconfig +1 -0
index 6c5c1a92712..26729b33c59 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_SIZE=0x10000
 CONFIG_ENV_OFFSET=0x200000
 CONFIG_DEFAULT_DEVICE_TREE="tegra20-colibri"
 CONFIG_OF_LIBFDT_OVERLAY=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffffc
 CONFIG_SPL_TEXT_BASE=0x00108000
 CONFIG_SYS_LOAD_ADDR=0x1000000
configs/colibri_t30_defconfig +1 -0
index 4f2dde6d84a..3c747238f4a 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFDE00
 CONFIG_DEFAULT_DEVICE_TREE="tegra30-colibri"
 CONFIG_OF_LIBFDT_OVERLAY=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x81000000
configs/controlcenterdc_defconfig +1 -0
index 2d6c83a5d5f..47805dc1e62 100644
@@ -15,6 +15,7 @@ CONFIG_ENV_OFFSET=0x100000
 CONFIG_ENV_SECT_SIZE=0x40000
 CONFIG_DEFAULT_DEVICE_TREE="armada-38x-controlcenterdc"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x40031000
 CONFIG_SPL_TEXT_BASE=0x40000030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/corvus_defconfig +1 -0
index ce2f4f7d91e..a8d61f3b45a 100644
@@ -19,6 +19,7 @@ CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x70007f00
 CONFIG_ENV_OFFSET=0x100000
 CONFIG_DEFAULT_DEVICE_TREE="at91sam9g45-corvus"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4000
 CONFIG_SPL_TEXT_BASE=0x300000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/da850evm_defconfig +1 -0
index 4cddc7f5836..8f3a3f971ed 100644
@@ -20,6 +20,7 @@ CONFIG_ENV_SECT_SIZE=0x10000
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="ti/davinci/da850-evm"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x8001ff00
 CONFIG_SPL_TEXT_BASE=0x80000000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/da850evm_nand_defconfig +1 -0
index b8b1a96c16a..4827c0665fc 100644
@@ -17,6 +17,7 @@ CONFIG_ENV_OFFSET=0x0
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="ti/davinci/da850-evm"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x8001ff00
 CONFIG_SPL_TEXT_BASE=0x80000000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/dalmore_defconfig +1 -0
index 4dba3717abb..52a947868a0 100644
@@ -8,6 +8,7 @@ CONFIG_SF_DEFAULT_SPEED=24000000
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFE000
 CONFIG_DEFAULT_DEVICE_TREE="tegra114-dalmore"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x81000000
configs/db-88f6720_defconfig +1 -0
index d2f400dae8d..c82c247bb07 100644
@@ -13,6 +13,7 @@ CONFIG_ENV_OFFSET=0x100000
 CONFIG_ENV_SECT_SIZE=0x10000
 CONFIG_DEFAULT_DEVICE_TREE="armada-375-db"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40000030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/db-88f6820-amc_defconfig +1 -0
index 23fe44faf51..d4a1ddddc79 100644
@@ -13,6 +13,7 @@ CONFIG_ENV_OFFSET=0x100000
 CONFIG_ENV_SECT_SIZE=0x40000
 CONFIG_DEFAULT_DEVICE_TREE="armada-385-db-88f6820-amc"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40000030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/db-88f6820-amc_nand_defconfig +1 -0
index f0dd977748b..f357e262126 100644
@@ -15,6 +15,7 @@ CONFIG_ENV_OFFSET=0x100000
 CONFIG_ENV_SECT_SIZE=0x40000
 CONFIG_DEFAULT_DEVICE_TREE="armada-385-db-88f6820-amc"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40000030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/db-88f6820-gp_defconfig +1 -0
index cb017a72551..17a0f668bff 100644
@@ -13,6 +13,7 @@ CONFIG_ENV_OFFSET=0x100000
 CONFIG_ENV_SECT_SIZE=0x40000
 CONFIG_DEFAULT_DEVICE_TREE="armada-388-gp"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40000030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/db-mv784mp-gp_defconfig +1 -0
index a417c944b0f..5b9efeab98f 100644
@@ -13,6 +13,7 @@ CONFIG_ENV_OFFSET=0x100000
 CONFIG_ENV_SECT_SIZE=0x10000
 CONFIG_DEFAULT_DEVICE_TREE="armada-xp-gp"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40004030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/ds116_defconfig +1 -0
index 8562874ecde..67bcc15bccf 100644
@@ -18,6 +18,7 @@ CONFIG_ENV_OFFSET=0x7E0000
 CONFIG_ENV_SECT_SIZE=0x10000
 CONFIG_DEFAULT_DEVICE_TREE="marvell/armada-385-synology-ds116"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40000030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/ds414_defconfig +1 -0
index 25e5be3ba7d..c0b2709c60a 100644
@@ -18,6 +18,7 @@ CONFIG_ENV_OFFSET=0x7E0000
 CONFIG_ENV_SECT_SIZE=0x10000
 CONFIG_DEFAULT_DEVICE_TREE="armada-xp-synology-ds414"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40004030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/endeavoru_defconfig +1 -0
index 1d1f1042291..a54becfe6ed 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_SOURCE_FILE="endeavoru"
 CONFIG_ENV_SIZE=0x3000
 CONFIG_ENV_OFFSET=0xFFFFD000
 CONFIG_DEFAULT_DEVICE_TREE="tegra30-htc-endeavoru"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x82000000
configs/evb-px5_defconfig +1 -0
index b08714437fd..c9262417139 100644
@@ -16,6 +16,7 @@ CONFIG_TPL_LIBGENERIC_SUPPORT=y
 CONFIG_SPL_DRIVERS_MISC=y
 CONFIG_TARGET_EVB_PX5=y
 CONFIG_SPL_STACK_R_ADDR=0x600000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x188000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0x400000
configs/evb-rk3036_defconfig +1 -0
index ba79960495e..4e471f0ebb3 100644
@@ -14,6 +14,7 @@ CONFIG_SF_DEFAULT_SPEED=20000000
 CONFIG_DEFAULT_DEVICE_TREE="rk3036-sdk"
 CONFIG_ROCKCHIP_RK3036=y
 CONFIG_SPL_STACK_R_ADDR=0x80000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x10081fff
 CONFIG_SPL_TEXT_BASE=0x10081000
 CONFIG_SPL_STACK_R=y
configs/evb-rk3288_defconfig +1 -0
index ae79efebf57..f6b72a2b7a0 100644
@@ -15,6 +15,7 @@ CONFIG_SYS_MONITOR_LEN=614400
 CONFIG_ROCKCHIP_RK3288=y
 CONFIG_TARGET_EVB_RK3288=y
 CONFIG_SPL_STACK_R_ADDR=0x04000000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xff718000
 CONFIG_SPL_STACK_R=y
 CONFIG_SPL_STACK_R_MALLOC_SIMPLE_LEN=0x10000
configs/gardena-smart-gateway-at91sam_defconfig +1 -0
index c9eb661aab0..ecb451f07f9 100644
@@ -17,6 +17,7 @@ CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="at91sam9g25-gardena-smart-gateway"
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x308000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x1000
 CONFIG_SPL_TEXT_BASE=0x300000
configs/gose_defconfig +1 -0
index d212f91bf83..e8c7081a5ea 100644
@@ -14,6 +14,7 @@ CONFIG_ARCH_RENESAS_BOARD_STRING="Gose"
 CONFIG_R8A7793=y
 CONFIG_TARGET_GOSE=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6340000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x2000
 CONFIG_SPL=y
configs/grouper_defconfig +1 -0
index 9221ffb46a3..e0708a45abf 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_SOURCE_FILE="grouper"
 CONFIG_ENV_SIZE=0x3000
 CONFIG_ENV_OFFSET=0xFFFFD000
 CONFIG_DEFAULT_DEVICE_TREE="tegra30-asus-nexus7-grouper-E1565"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x82000000
configs/harmony_defconfig +1 -0
index d8cc8451bac..b21ba903a43 100644
@@ -6,6 +6,7 @@ CONFIG_NR_DRAM_BANKS=2
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0x1FFE0000
 CONFIG_DEFAULT_DEVICE_TREE="tegra20-harmony"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffffc
 CONFIG_SPL_TEXT_BASE=0x00108000
 CONFIG_SYS_LOAD_ADDR=0x1000000
configs/helios4_defconfig +1 -0
index 2778cb7dc86..08a46936ce8 100644
@@ -12,6 +12,7 @@ CONFIG_TARGET_HELIOS4=y
 CONFIG_MVEBU_SPL_BOOT_DEVICE_MMC=y
 CONFIG_DEFAULT_DEVICE_TREE="armada-388-helios4"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40000030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/ideapad-yoga-11_defconfig +1 -0
index 3c152cbfb98..2db116afe14 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_SOURCE_FILE="ideapad-yoga-11"
 CONFIG_ENV_SIZE=0x3000
 CONFIG_ENV_OFFSET=0xFFFFD000
 CONFIG_DEFAULT_DEVICE_TREE="tegra30-lenovo-ideapad-yoga-11"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x82000000
configs/imx28_xea_defconfig +1 -0
index 38282e6ea92..785c11f5093 100644
@@ -18,6 +18,7 @@ CONFIG_SPL_MXS_PMU_DISABLE_BATT_CHARGE=y
 # CONFIG_SPL_MXS_PMU_ENABLE_4P2_LINEAR_REGULATOR is not set
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x20000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x1000
 CONFIG_SPL_TEXT_BASE=0x1000
configs/imx8mm-cl-iot-gate-optee_defconfig +1 -0
index 722a5969732..c0c87da386b 100644
@@ -14,6 +14,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mm-cl-iot-gate_defconfig +1 -0
index 1aa42efe5ef..2dcf4aacb9b 100644
@@ -15,6 +15,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mm-icore-mx8mm-ctouch2_defconfig +1 -0
index db44145f650..330d73f05dd 100644
@@ -14,6 +14,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mm-icore-mx8mm-edimm2.2_defconfig +1 -0
index 94b4a9552cf..c2ffce47271 100644
@@ -14,6 +14,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mm-mx8menlo_defconfig +1 -0
index ae9595e82b4..880222e9f97 100644
@@ -17,6 +17,7 @@ CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
 CONFIG_BOOTCOUNT_BOOTLIMIT=3
 CONFIG_SYS_BOOTCOUNT_ADDR=0x30370090
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mm-phygate-tauri-l_defconfig +1 -0
index 18fffa7405e..7a418e748ce 100644
@@ -14,6 +14,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mm_beacon_defconfig +1 -0
index 56e18893b77..e3f29ddf2e5 100644
@@ -16,6 +16,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mm_beacon_fspi_defconfig +1 -0
index 2a8bd2df940..3d1630a8750 100644
@@ -16,6 +16,7 @@ CONFIG_TARGET_IMX8MM_BEACON=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E2000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mm_data_modul_edm_sbc_defconfig +1 -0
index 105fbfb4d9b..c2e9ddf6a8b 100644
@@ -21,6 +21,7 @@ CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
 CONFIG_BOOTCOUNT_BOOTLIMIT=3
 CONFIG_SYS_BOOTCOUNT_ADDR=0x30370090
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mm_evk_defconfig +1 -0
index 90757100c72..8160ae35bbc 100644
@@ -14,6 +14,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mm_evk_fspi_defconfig +1 -0
index fb4a4421cf0..4e69d938003 100644
@@ -17,6 +17,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E2000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mm_phg_defconfig +1 -0
index 384f2cc7b76..55639d6ea8f 100644
@@ -14,6 +14,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mm_venice_defconfig +1 -0
index da248e4887e..3c8df880661 100644
@@ -16,6 +16,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mn_beacon_2g_defconfig +1 -0
index b72fa93f90e..bb61f6b9b96 100644
@@ -19,6 +19,7 @@ CONFIG_DM_RESET=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x980000
 CONFIG_SPL_TEXT_BASE=0x912000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mn_beacon_defconfig +1 -0
index 69af7cee092..5de3a79fc80 100644
@@ -18,6 +18,7 @@ CONFIG_DM_RESET=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x980000
 CONFIG_SPL_TEXT_BASE=0x912000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mn_beacon_fspi_defconfig +1 -0
index b90cb9002bd..b02ee69a375 100644
@@ -18,6 +18,7 @@ CONFIG_DM_RESET=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x980000
 CONFIG_SPL_TEXT_BASE=0x912000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mn_bsh_smm_s2_defconfig +1 -0
index f4a04744667..51aebc31dcb 100644
@@ -14,6 +14,7 @@ CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x980000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x2000
 CONFIG_SPL_TEXT_BASE=0x912000
configs/imx8mn_bsh_smm_s2pro_defconfig +1 -0
index 9ca96a7f66f..52e6a358549 100644
@@ -15,6 +15,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x980000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x2000
 CONFIG_SPL_TEXT_BASE=0x912000
configs/imx8mn_ddr4_evk_defconfig +1 -0
index 3eb58d61c83..8e4289869f8 100644
@@ -14,6 +14,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x980000
 CONFIG_SPL_TEXT_BASE=0x912000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mn_evk_defconfig +1 -0
index 43860fe3f56..2eacb4dda6c 100644
@@ -14,6 +14,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x980000
 CONFIG_SPL_TEXT_BASE=0x912000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mn_var_som_defconfig +1 -0
index 9016c404017..b655aa77090 100644
@@ -16,6 +16,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x980000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x2000
 CONFIG_SPL_TEXT_BASE=0x912000
configs/imx8mn_venice_defconfig +1 -0
index 44af3e61d5d..99a8f83a773 100644
@@ -15,6 +15,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x980000
 CONFIG_SPL_TEXT_BASE=0x912000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mp-icore-mx8mp-edimm2.2_defconfig +1 -0
index d7d5df77c5a..2a97af69a29 100644
@@ -17,6 +17,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x960000
 CONFIG_SPL_TEXT_BASE=0x920000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mp_beacon_defconfig +1 -0
index f39e4f5dd28..33fc0b8aa70 100644
@@ -19,6 +19,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x960000
 CONFIG_SPL_TEXT_BASE=0x920000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mp_data_modul_edm_sbc_defconfig +1 -0
index f809d23d6d2..1ee4ff16c5f 100644
@@ -22,6 +22,7 @@ CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
 CONFIG_BOOTCOUNT_BOOTLIMIT=3
 CONFIG_SYS_BOOTCOUNT_ADDR=0x30370090
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x96fc00
 CONFIG_SPL_TEXT_BASE=0x920000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mp_debix_model_a_defconfig +1 -0
index 560ac12b10d..14f62fbccb2 100644
@@ -14,6 +14,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x960000
 CONFIG_SPL_TEXT_BASE=0x920000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mp_dhsom.config +1 -0
index 416143178c8..3980c410266 100644
@@ -41,6 +41,7 @@ CONFIG_SPL_LOAD_FIT_ADDRESS=0x44000000
 CONFIG_SPL_LOAD_FIT_APPLY_OVERLAY=y
 CONFIG_SPL_MAX_SIZE=0x26000
 CONFIG_SPL_OF_CONTROL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x96fc00
 CONFIG_SPL_SYS_MALLOC_SIZE=0x80000
 CONFIG_SPL_TEXT_BASE=0x920000
configs/imx8mp_evk_defconfig +1 -0
index 5369f8b84a4..f1a7c6911ba 100644
@@ -14,6 +14,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x960000
 CONFIG_SPL_TEXT_BASE=0x920000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mp_navqp_defconfig +1 -0
index 6c7eb330b70..bdb9d14b36e 100644
@@ -14,6 +14,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x960000
 CONFIG_SPL_TEXT_BASE=0x920000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mp_rsb3720a1_4G_defconfig +1 -0
index bfcda77b37e..3d7432a0af4 100644
@@ -20,6 +20,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x960000
 CONFIG_SPL_TEXT_BASE=0x920000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mp_rsb3720a1_6G_defconfig +1 -0
index 69e67bcd498..553b2504390 100644
@@ -20,6 +20,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x960000
 CONFIG_SPL_TEXT_BASE=0x920000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mp_venice_defconfig +1 -0
index bf296b13e2b..cdbd981dab3 100644
@@ -16,6 +16,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x960000
 CONFIG_SPL_TEXT_BASE=0x920000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mq_cm_defconfig +1 -0
index 7444b642aa5..2d4ca5a798c 100644
@@ -16,6 +16,7 @@ CONFIG_TARGET_IMX8MQ_CM=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x187ff0
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mq_evk_defconfig +1 -0
index a3a2333c982..8c565346ce8 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x187ff0
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mq_phanbell_defconfig +1 -0
index a3727390dc7..19ec1d27c84 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x187ff0
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8mq_reform2_defconfig +1 -0
index 1a6d6dcb8be..c6423c8ac61 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x187ff0
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8qm_dmsse20a1_defconfig +1 -0
index 9f2a6d78cee..83ac175c2fc 100644
@@ -20,6 +20,7 @@ CONFIG_TARGET_IMX8QM_DMSSE20_A1=y
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x13e000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0x128000
configs/imx8qm_mek_defconfig +1 -0
index 9bbbc6a4912..dd1d6ebd95a 100644
@@ -17,6 +17,7 @@ CONFIG_TARGET_IMX8QM_MEK=y
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x13e000
 CONFIG_SPL_TEXT_BASE=0x100000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8qxp_mek_defconfig +1 -0
index dfb288b9861..e5079751040 100644
@@ -17,6 +17,7 @@ CONFIG_TARGET_IMX8QXP_MEK=y
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x13e000
 CONFIG_SPL_TEXT_BASE=0x100000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx8ulp_evk_defconfig +1 -0
index cccc3153f50..06523f88746 100644
@@ -15,6 +15,7 @@ CONFIG_TARGET_IMX8ULP_EVK=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x22050000
 CONFIG_SPL_TEXT_BASE=0x22020000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx93-phycore_defconfig +1 -0
index cf9800118ac..1f75b7cfdef 100644
@@ -19,6 +19,7 @@ CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x20519dd0
 CONFIG_SPL_TEXT_BASE=0x2049A000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx93_11x11_evk_defconfig +1 -0
index df62eecdde4..7161c54162a 100644
@@ -15,6 +15,7 @@ CONFIG_TARGET_IMX93_11X11_EVK=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x20519dd0
 CONFIG_SPL_TEXT_BASE=0x2049A000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/imx93_9x9_qsb_defconfig +1 -0
index 582fe5a318d..2db1c472ee0 100644
@@ -17,6 +17,7 @@ CONFIG_TARGET_IMX93_9X9_QSB=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x20519dd0
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x18000
 CONFIG_SPL_TEXT_BASE=0x2049A000
configs/imx93_9x9_qsb_inline_ecc_defconfig +1 -0
index c95145cce0e..e6e75c9a18a 100644
@@ -17,6 +17,7 @@ CONFIG_TARGET_IMX93_9X9_QSB=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x20519dd0
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x18000
 CONFIG_SPL_TEXT_BASE=0x2049A000
configs/imx93_var_som_defconfig +1 -0
index 96cd8622e90..a6649126989 100644
@@ -16,6 +16,7 @@ CONFIG_TARGET_IMX93_VAR_SOM=y
 CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x20519dd0
 CONFIG_SPL_TEXT_BASE=0x2049A000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/jetson-tk1_defconfig +1 -0
index b92590eb5fd..d8a0f1f56d9 100644
@@ -9,6 +9,7 @@ CONFIG_SF_DEFAULT_SPEED=24000000
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFE000
 CONFIG_DEFAULT_DEVICE_TREE="tegra124-jetson-tk1"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x81000000
configs/k2e_evm_defconfig +1 -0
index c2073096b6e..2b60d1fbd84 100644
@@ -20,6 +20,7 @@ CONFIG_ENV_OFFSET=0x100000
 CONFIG_SPL_DM_SPI=y
 CONFIG_DEFAULT_DEVICE_TREE="ti/keystone/keystone-k2e-evm"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xc1223f4
 CONFIG_SPL_TEXT_BASE=0xC100000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/k2g_evm_defconfig +1 -0
index c93e82a7c59..2256c7143cd 100644
@@ -19,6 +19,7 @@ CONFIG_ENV_SIZE=0x40000
 CONFIG_SPL_DM_SPI=y
 CONFIG_DEFAULT_DEVICE_TREE="ti/keystone/keystone-k2g-evm"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xc0c23f4
 CONFIG_SPL_TEXT_BASE=0xC0A0000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/k2hk_evm_defconfig +1 -0
index 7ae7a3ba83c..cf387901eb9 100644
@@ -20,6 +20,7 @@ CONFIG_ENV_OFFSET=0x100000
 CONFIG_SPL_DM_SPI=y
 CONFIG_DEFAULT_DEVICE_TREE="ti/keystone/keystone-k2hk-evm"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xc2223f4
 CONFIG_SPL_TEXT_BASE=0xC200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/k2l_evm_defconfig +1 -0
index 9f08e9d7995..4a1aa6018e0 100644
@@ -20,6 +20,7 @@ CONFIG_ENV_OFFSET=0x100000
 CONFIG_SPL_DM_SPI=y
 CONFIG_DEFAULT_DEVICE_TREE="ti/keystone/keystone-k2l-evm"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xc1223f4
 CONFIG_SPL_TEXT_BASE=0xC100000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/koelsch_defconfig +1 -0
index 9bce9e33104..0735b31a212 100644
@@ -14,6 +14,7 @@ CONFIG_ARCH_RENESAS_BOARD_STRING="Koelsch"
 CONFIG_R8A7791=y
 CONFIG_TARGET_KOELSCH=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6340000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x2000
 CONFIG_SPL=y
configs/kontron-sl-mx8mm_defconfig +1 -0
index f2d5bc1e7ab..ac146e83e71 100644
@@ -18,6 +18,7 @@ CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
 CONFIG_BOOTCOUNT_BOOTLIMIT=3
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x91fff0
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/kontron_pitx_imx8m_defconfig +1 -0
index 6e21870f006..6206f418519 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x187ff0
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/kontron_sl28_defconfig +1 -0
index 35894a10cbe..cf766f7c557 100644
@@ -17,6 +17,7 @@ CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_SYS_MONITOR_LEN=1048576
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x18009ff0
 CONFIG_SPL_TEXT_BASE=0x18010000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/kylin-rk3036_defconfig +1 -0
index dd25fd60107..1ebb703c6fa 100644
@@ -16,6 +16,7 @@ CONFIG_DEFAULT_DEVICE_TREE="rk3036-sdk"
 CONFIG_ROCKCHIP_RK3036=y
 CONFIG_TARGET_KYLIN_RK3036=y
 CONFIG_SPL_STACK_R_ADDR=0x80000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x10081fff
 CONFIG_SPL_TEXT_BASE=0x10081000
 CONFIG_SPL_STACK_R=y
configs/lager_defconfig +1 -0
index 0d4eed0ddf7..3419af62bc0 100644
@@ -14,6 +14,7 @@ CONFIG_ARCH_RENESAS_BOARD_STRING="Lager"
 CONFIG_R8A7790=y
 CONFIG_TARGET_LAGER=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6340000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x2000
 CONFIG_SPL=y
configs/librem5_defconfig +1 -0
index f81e828e4de..b39f9592d1e 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x187ff0
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/ls1021aiot_sdcard_defconfig +1 -0
index f195d077687..46018e6429a 100644
@@ -16,6 +16,7 @@ CONFIG_DEFAULT_DEVICE_TREE="ls1021a-iot-duart"
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x1001d000
 CONFIG_SPL_TEXT_BASE=0x10000000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/ls1021aqds_nand_defconfig +1 -0
index 97d01225389..bbad2cd2df7 100644
@@ -18,6 +18,7 @@ CONFIG_DEFAULT_DEVICE_TREE="ls1021a-qds-duart"
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x1001d000
 CONFIG_SPL_TEXT_BASE=0x10000000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/ls1021aqds_sdcard_ifc_defconfig +1 -0
index 96314d542df..932edd0f81a 100644
@@ -19,6 +19,7 @@ CONFIG_SYS_MONITOR_LEN=786432
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x1001d000
 CONFIG_SPL_TEXT_BASE=0x10000000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/ls1021aqds_sdcard_qspi_defconfig +1 -0
index e466c3df145..a9ce741eb2a 100644
@@ -19,6 +19,7 @@ CONFIG_SYS_MONITOR_LEN=786432
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x1001d000
 CONFIG_SPL_TEXT_BASE=0x10000000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/ls1021atsn_sdcard_defconfig +1 -0
index 86ee5315b42..eb57f8b099c 100644
@@ -16,6 +16,7 @@ CONFIG_DEFAULT_DEVICE_TREE="ls1021a-tsn"
 CONFIG_SYS_MONITOR_LEN=1048576
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x1001d000
 CONFIG_SPL_TEXT_BASE=0x10000000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/ls1021atwr_sdcard_ifc_SECURE_BOOT_defconfig +1 -0
index 7dc3241124f..c5623d98962 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=1064960
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x1001d000
 CONFIG_SPL_TEXT_BASE=0x10000000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/ls1021atwr_sdcard_ifc_defconfig +1 -0
index d62126274e5..d635e8851ac 100644
@@ -18,6 +18,7 @@ CONFIG_DEFAULT_DEVICE_TREE="ls1021a-twr-duart"
 CONFIG_SYS_MONITOR_LEN=1048576
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x1001d000
 CONFIG_SPL_TEXT_BASE=0x10000000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/ls1021atwr_sdcard_qspi_defconfig +1 -0
index 53f487da198..df4cc77fbae 100644
@@ -18,6 +18,7 @@ CONFIG_DEFAULT_DEVICE_TREE="ls1021a-twr-duart"
 CONFIG_SYS_MONITOR_LEN=1048576
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x1001d000
 CONFIG_SPL_TEXT_BASE=0x10000000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/ls2080aqds_nand_defconfig +1 -0
index 755411ed853..6442ecff509 100644
@@ -16,6 +16,7 @@ CONFIG_DEFAULT_DEVICE_TREE="fsl-ls2080a-qds"
 CONFIG_SYS_MONITOR_LEN=1048576
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x18009ff0
 CONFIG_SPL_TEXT_BASE=0x1800a000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/ls2080ardb_nand_defconfig +1 -0
index 1be0b4e88cb..10d195ffd44 100644
@@ -16,6 +16,7 @@ CONFIG_DEFAULT_DEVICE_TREE="fsl-ls2080a-rdb"
 CONFIG_SYS_MONITOR_LEN=1048576
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x18009ff0
 CONFIG_SPL_TEXT_BASE=0x1800a000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/m53menlo_defconfig +1 -0
index 6130cd8e466..bc751adfab2 100644
@@ -16,6 +16,7 @@ CONFIG_DEFAULT_DEVICE_TREE="imx53-m53menlo"
 CONFIG_SPL_SERIAL=y
 CONFIG_BOOTCOUNT_BOOTLIMIT=3
 CONFIG_SYS_BOOTCOUNT_ADDR=0x53FA401C
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x70004000
 CONFIG_SPL_TEXT_BASE=0x70008000
 CONFIG_SYS_LOAD_ADDR=0x70800000
configs/maxbcm_defconfig +1 -0
index bf9cbff53be..ea8a00d724b 100644
@@ -13,6 +13,7 @@ CONFIG_ENV_OFFSET=0x100000
 CONFIG_ENV_SECT_SIZE=0x10000
 CONFIG_DEFAULT_DEVICE_TREE="armada-xp-maxbcm"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40004030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/medcom-wide_defconfig +1 -0
index def3f98bd72..f8dca06ab45 100644
@@ -6,6 +6,7 @@ CONFIG_NR_DRAM_BANKS=2
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0x1FFE0000
 CONFIG_DEFAULT_DEVICE_TREE="tegra20-medcom-wide"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffffc
 CONFIG_SPL_TEXT_BASE=0x00108000
 CONFIG_SYS_LOAD_ADDR=0x1000000
configs/microblaze-generic_defconfig +1 -0
index 2e618d81544..5c728e328ad 100644
@@ -7,6 +7,7 @@ CONFIG_ENV_SIZE=0x20000
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="microblaze-generic"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x100000
 CONFIG_SYS_BOOTM_LEN=0x4000000
 CONFIG_SYS_LOAD_ADDR=0x0
configs/mk808_defconfig +1 -0
index a1f089a23ea..8c7f4deb843 100644
@@ -22,6 +22,7 @@ CONFIG_TPL_TEXT_BASE=0x10080c00
 CONFIG_TPL_STACK=0x1008FFFF
 CONFIG_TARGET_MK808=y
 CONFIG_SPL_STACK_R_ADDR=0x70000000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x1008ffff
 CONFIG_SPL_TEXT_BASE=0x60000000
 CONFIG_SPL_STACK_R=y
configs/msc_sm2s_imx8mp_defconfig +1 -0
index def90d470b1..387fb06460c 100644
@@ -14,6 +14,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x960000
 CONFIG_SPL_TEXT_BASE=0x920000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/mt7629_rfb_defconfig +1 -0
index abdf3d0cc49..cc54d0dd792 100644
@@ -14,6 +14,7 @@ CONFIG_TARGET_MT7629=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
 CONFIG_SPL_STACK_R_ADDR=0x40800000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x106000
 CONFIG_SPL_TEXT_BASE=0x201000
 CONFIG_SPL_STACK_R=y
configs/n2350_defconfig +1 -0
index 9fb84c3b946..34646a4025f 100644
@@ -18,6 +18,7 @@ CONFIG_ENV_OFFSET=0x100000
 CONFIG_ENV_SECT_SIZE=0x1000
 CONFIG_DEFAULT_DEVICE_TREE="armada-385-thecus-n2350"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40000030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/nyan-big_defconfig +1 -0
index 9054ec54ff9..a3ce34376b1 100644
@@ -8,6 +8,7 @@ CONFIG_SF_DEFAULT_SPEED=24000000
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFE000
 CONFIG_DEFAULT_DEVICE_TREE="tegra124-nyan-big"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x82408000
configs/omapl138_lcdk_defconfig +1 -0
index b9ea355151e..fb0a482d411 100644
@@ -21,6 +21,7 @@ CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="da850-lcdk"
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x8001ff00
 CONFIG_SPL_TEXT_BASE=0x80000000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/openpiton_riscv64_spl_defconfig +1 -0
index 09054d93047..b0e8ad11a8b 100644
@@ -6,6 +6,7 @@ CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
 CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x82000000
 CONFIG_DEFAULT_DEVICE_TREE="openpiton-riscv64"
 CONFIG_OF_LIBFDT_OVERLAY=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x83fffe80
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x100000
 CONFIG_SPL_BSS_START_ADDR=0x82000000
configs/paz00_defconfig +1 -0
index e93fa1c003a..c2cd73d3e8e 100644
@@ -6,6 +6,7 @@ CONFIG_NR_DRAM_BANKS=2
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFE000
 CONFIG_DEFAULT_DEVICE_TREE="tegra20-paz00"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffffc
 CONFIG_SPL_TEXT_BASE=0x00108000
 CONFIG_SYS_LOAD_ADDR=0x1000000
configs/phycore-imx8mm_defconfig +1 -0
index c24580430f2..56cbd818cb2 100644
@@ -17,6 +17,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/phycore-imx8mp_defconfig +1 -0
index 23981826109..fdeb4c4b7f0 100644
@@ -19,6 +19,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x960000
 CONFIG_SPL_TEXT_BASE=0x920000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/phycore-rk3288_defconfig +1 -0
index 0f8e999ee3f..ff03a59b48d 100644
@@ -14,6 +14,7 @@ CONFIG_ROCKCHIP_RK3288=y
 CONFIG_SPL_ROCKCHIP_BACK_TO_BROM=y
 CONFIG_TARGET_PHYCORE_RK3288=y
 CONFIG_SPL_STACK_R_ADDR=0x80000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xff718000
 CONFIG_SPL_TEXT_BASE=0xff704000
 CONFIG_SPL_STACK_R=y
configs/pico-imx8mq_defconfig +1 -0
index e9ba2a6bf42..7245e54fa4d 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x187ff0
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/plutux_defconfig +1 -0
index 1f2889ea8b1..43a3c8e04ee 100644
@@ -6,6 +6,7 @@ CONFIG_NR_DRAM_BANKS=2
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0x1FFE0000
 CONFIG_DEFAULT_DEVICE_TREE="tegra20-plutux"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffffc
 CONFIG_SPL_TEXT_BASE=0x00108000
 CONFIG_SYS_LOAD_ADDR=0x1000000
configs/popmetal-rk3288_defconfig +1 -0
index 1b2fb4a38cd..ae7869ae5fa 100644
@@ -14,6 +14,7 @@ CONFIG_ROCKCHIP_RK3288=y
 CONFIG_SPL_ROCKCHIP_BACK_TO_BROM=y
 CONFIG_TARGET_POPMETAL_RK3288=y
 CONFIG_SPL_STACK_R_ADDR=0x80000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xff718000
 CONFIG_SPL_TEXT_BASE=0xff704000
 CONFIG_SPL_STACK_R=y
configs/porter_defconfig +1 -0
index 98a67bee3e0..2419e0263e2 100644
@@ -14,6 +14,7 @@ CONFIG_ARCH_RENESAS_BOARD_STRING="Porter"
 CONFIG_R8A7791=y
 CONFIG_TARGET_PORTER=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6340000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x2000
 CONFIG_SPL=y
configs/qc750_defconfig +1 -0
index 2485e64a2f0..4f830bea20e 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_SOURCE_FILE="qc750"
 CONFIG_ENV_SIZE=0x3000
 CONFIG_ENV_OFFSET=0xFFFFD000
 CONFIG_DEFAULT_DEVICE_TREE="tegra30-wexler-qc750"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x82000000
configs/r8a77970_eagle_defconfig +1 -0
index 4534b17adc1..0a03e6d0d9d 100644
@@ -13,6 +13,7 @@ CONFIG_ENV_SECT_SIZE=0x40000
 CONFIG_DEFAULT_DEVICE_TREE="renesas/r8a77970-eagle"
 CONFIG_SPL_TEXT_BASE=0xe6318000
 CONFIG_TARGET_EAGLE=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6304000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0xe631f000
configs/r8a77970_v3msk_defconfig +1 -0
index 4a146e1c859..96a5b81ed20 100644
@@ -14,6 +14,7 @@ CONFIG_DEFAULT_DEVICE_TREE="renesas/r8a77970-v3msk"
 CONFIG_SPL_TEXT_BASE=0xe6318000
 CONFIG_R8A77970=y
 CONFIG_TARGET_V3MSK=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6304000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0xe631f000
configs/r8a77980_condor_defconfig +1 -0
index 9cf93d7dab2..d46548256d7 100644
@@ -12,6 +12,7 @@ CONFIG_ENV_SECT_SIZE=0x40000
 CONFIG_DEFAULT_DEVICE_TREE="renesas/r8a77980-condor"
 CONFIG_SPL_TEXT_BASE=0xe6318000
 CONFIG_TARGET_CONDOR=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6304000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0xe631f000
configs/r8a77980_v3hsk_defconfig +1 -0
index d17720789e7..51e8d2bd368 100644
@@ -13,6 +13,7 @@ CONFIG_DEFAULT_DEVICE_TREE="renesas/r8a77980-v3hsk"
 CONFIG_SPL_TEXT_BASE=0xe6318000
 CONFIG_R8A77980=y
 CONFIG_TARGET_V3HSK=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6304000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0xe631f000
configs/r8a77990_ebisu_defconfig +1 -0
index da93d442532..e7f63110420 100644
@@ -12,6 +12,7 @@ CONFIG_ENV_OFFSET=0xFFFE0000
 CONFIG_DEFAULT_DEVICE_TREE="renesas/r8a77990-ebisu"
 CONFIG_SPL_TEXT_BASE=0xe6318000
 CONFIG_TARGET_EBISU=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6304000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0xe631f000
configs/r8a77995_draak_defconfig +1 -0
index 0fe5be6b723..afabe788c45 100644
@@ -12,6 +12,7 @@ CONFIG_ENV_OFFSET=0xFFFE0000
 CONFIG_DEFAULT_DEVICE_TREE="renesas/r8a77995-draak"
 CONFIG_SPL_TEXT_BASE=0xe6318000
 CONFIG_TARGET_DRAAK=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6304000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0xe631f000
configs/rcar3_salvator-x_defconfig +1 -0
index 6b095f63549..adfe4e9490f 100644
@@ -10,6 +10,7 @@ CONFIG_ENV_OFFSET=0xFFFE0000
 CONFIG_DEFAULT_DEVICE_TREE="renesas/r8a77951-salvator-x"
 CONFIG_SPL_TEXT_BASE=0xe6338000
 CONFIG_TARGET_SALVATOR_X=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6304000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0xe633f000
configs/rcar3_ulcb_defconfig +1 -0
index 7ffa115cc76..52f7d8701dd 100644
@@ -11,6 +11,7 @@ CONFIG_ENV_OFFSET=0xFFFE0000
 CONFIG_DEFAULT_DEVICE_TREE="renesas/r8a77951-ulcb"
 CONFIG_SPL_TEXT_BASE=0xe6338000
 CONFIG_TARGET_ULCB=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6304000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0xe633f000
configs/rock-pi-n8-rk3288_defconfig +1 -0
index dde0b81eee4..92ffc72cd7a 100644
@@ -16,6 +16,7 @@ CONFIG_SYS_MONITOR_LEN=614400
 CONFIG_ROCKCHIP_RK3288=y
 CONFIG_TARGET_EVB_RK3288=y
 CONFIG_SPL_STACK_R_ADDR=0x80000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xff718000
 CONFIG_SPL_STACK_R=y
 CONFIG_SPL_STACK_R_MALLOC_SIMPLE_LEN=0x2000
configs/rock2_defconfig +1 -0
index bff65d1fc41..b356df23ec6 100644
@@ -14,6 +14,7 @@ CONFIG_ROCKCHIP_RK3288=y
 CONFIG_SPL_ROCKCHIP_BACK_TO_BROM=y
 CONFIG_TARGET_ROCK2=y
 CONFIG_SPL_STACK_R_ADDR=0x80000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xff718000
 CONFIG_SPL_TEXT_BASE=0xff704000
 CONFIG_SPL_STACK_R=y
configs/rock_defconfig +1 -0
index 9c05bf45146..d2a84710cb0 100644
@@ -16,6 +16,7 @@ CONFIG_ROCKCHIP_RK3188=y
 # CONFIG_ROCKCHIP_STIMER is not set
 CONFIG_TARGET_ROCK=y
 CONFIG_SPL_STACK_R_ADDR=0x60080000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x10087fff
 CONFIG_SPL_TEXT_BASE=0x10080800
 CONFIG_SPL_STACK_R=y
configs/sama5d27_giantboard_defconfig +1 -0
index 70e3ea10dbe..e7fb2c40b9e 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d27_som1_ek_mmc1_defconfig +1 -0
index 9246ede4ef2..c590331b7fe 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d27_som1_ek_mmc_defconfig +1 -0
index 4be4245e1f7..74cc6c91aaa 100644
@@ -19,6 +19,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d27_som1_ek_qspiflash_defconfig +1 -0
index cdd10608e79..c169b5bbf5b 100644
@@ -19,6 +19,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d27_wlsom1_ek_mmc_defconfig +1 -0
index cc69a41f64c..770f56959b3 100644
@@ -17,6 +17,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d27_wlsom1_ek_qspiflash_defconfig +1 -0
index beab5d09db3..41effc845b4 100644
@@ -17,6 +17,7 @@ CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d2_icp_mmc_defconfig +1 -0
index 5e8b9b975e4..840c65d7c02 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0x20000000
configs/sama5d2_xplained_emmc_defconfig +1 -0
index 736a6eeaf87..4f0425a8224 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d2_xplained_mmc_defconfig +1 -0
index 6fd1075ebdc..893f88c9e09 100644
@@ -19,6 +19,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d2_xplained_qspiflash_defconfig +1 -0
index 4c30e9daa40..36d5e260243 100644
@@ -19,6 +19,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d2_xplained_spiflash_defconfig +1 -0
index 9431ff1caac..7fc2ee8be33 100644
@@ -21,6 +21,7 @@ CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d3_xplained_mmc_defconfig +1 -0
index 0050d95188e..c0a3b0fbcc5 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=1048576
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x318000
 CONFIG_SPL_TEXT_BASE=0x300000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d3_xplained_nandflash_defconfig +1 -0
index 6a66637a9dc..6092b1458f2 100644
@@ -16,6 +16,7 @@ CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_SYS_MONITOR_LEN=1048576
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x318000
 CONFIG_SPL_TEXT_BASE=0x300000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d3xek_mmc_defconfig +1 -0
index 4c7914673bf..677211ac8f0 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x318000
 CONFIG_SPL_TEXT_BASE=0x300000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d3xek_nandflash_defconfig +1 -0
index 985a152ea42..f724ad054e5 100644
@@ -16,6 +16,7 @@ CONFIG_DEFAULT_DEVICE_TREE="sama5d36ek"
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x318000
 CONFIG_SPL_TEXT_BASE=0x300000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d3xek_spiflash_defconfig +1 -0
index 3f2bd734638..f0ac8014b74 100644
@@ -20,6 +20,7 @@ CONFIG_DEFAULT_DEVICE_TREE="sama5d36ek"
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x318000
 CONFIG_SPL_TEXT_BASE=0x300000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d4_xplained_mmc_defconfig +1 -0
index f0c4356cc9e..d08154fcd1c 100644
@@ -19,6 +19,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d4_xplained_nandflash_defconfig +1 -0
index 4d6ca43a6cb..20b6fec563d 100644
@@ -17,6 +17,7 @@ CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d4_xplained_spiflash_defconfig +1 -0
index c0680fbcb0d..5bb74238a54 100644
@@ -21,6 +21,7 @@ CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d4ek_mmc_defconfig +1 -0
index 347ccb47c89..5668982ae85 100644
@@ -18,6 +18,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d4ek_nandflash_defconfig +1 -0
index b309b87dc6b..6ac5a5d7659 100644
@@ -16,6 +16,7 @@ CONFIG_DEFAULT_DEVICE_TREE="at91-sama5d4ek"
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/sama5d4ek_spiflash_defconfig +1 -0
index 38edafc1879..1c76f1a4aa3 100644
@@ -20,6 +20,7 @@ CONFIG_DEFAULT_DEVICE_TREE="at91-sama5d4ek"
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x218000
 CONFIG_SPL_TEXT_BASE=0x200000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/seaboard_defconfig +1 -0
index 090dc04112a..597f8760188 100644
@@ -6,6 +6,7 @@ CONFIG_NR_DRAM_BANKS=2
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFE000
 CONFIG_DEFAULT_DEVICE_TREE="tegra20-seaboard"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffffc
 CONFIG_SPL_TEXT_BASE=0x00108000
 CONFIG_SYS_LOAD_ADDR=0x1000000
configs/sifive_unleashed_defconfig +1 -0
index 96b6f482c4f..04c1ae7d83f 100644
@@ -9,6 +9,7 @@ CONFIG_SPL_DM_SPI=y
 CONFIG_DEFAULT_DEVICE_TREE="hifive-unleashed-a00"
 CONFIG_DM_RESET=y
 CONFIG_SPL_MMC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x81cfe70
 CONFIG_SPL_BSS_START_ADDR=0x85000000
 CONFIG_SYS_BOOTM_LEN=0x4000000
configs/sifive_unmatched_defconfig +1 -0
index 058e5fab683..34770df35ff 100644
@@ -10,6 +10,7 @@ CONFIG_SPL_DM_SPI=y
 CONFIG_DEFAULT_DEVICE_TREE="hifive-unmatched-a00"
 CONFIG_DM_RESET=y
 CONFIG_SPL_MMC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x81cfe60
 CONFIG_SPL_BSS_START_ADDR=0x85000000
 CONFIG_SYS_BOOTM_LEN=0x4000000
configs/silinux_ek874_defconfig +1 -0
index 031fdc02691..c9a44247a86 100644
@@ -13,6 +13,7 @@ CONFIG_ENV_SECT_SIZE=0x10000
 CONFIG_DEFAULT_DEVICE_TREE="renesas/r8a774c0-ek874"
 CONFIG_SPL_TEXT_BASE=0xe6318000
 CONFIG_TARGET_SILINUX_EK874=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6304000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0xe631f000
configs/silk_defconfig +1 -0
index 53597e9dd4d..20caffa3c7e 100644
@@ -14,6 +14,7 @@ CONFIG_ARCH_RENESAS_BOARD_STRING="Silk"
 CONFIG_R8A7794=y
 CONFIG_TARGET_SILK=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6340000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x2000
 CONFIG_SPL=y
configs/smartweb_defconfig +1 -0
index aa8adf51181..e765d77cabe 100644
@@ -17,6 +17,7 @@ CONFIG_SPL_LIBGENERIC_SUPPORT=y
 CONFIG_NR_DRAM_BANKS=1
 CONFIG_ENV_OFFSET=0x100000
 CONFIG_DEFAULT_DEVICE_TREE="at91sam9260-smartweb"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x301000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x400
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/socfpga_agilex5_defconfig +1 -0
index 8577ac610c2..70337eb29d1 100644
@@ -10,6 +10,7 @@ CONFIG_ENV_SIZE=0x2000
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_agilex5_socdk"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x7f000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0xbff00000
configs/socfpga_agilex_atf_defconfig +1 -0
index 8c4f7072aa8..26f2fa2fa8e 100644
@@ -13,6 +13,7 @@ CONFIG_ENV_OFFSET=0x200
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_agilex_socdk"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffe3f000
 CONFIG_SPL_TEXT_BASE=0xFFE00000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/socfpga_agilex_defconfig +1 -0
index eaa2161a2f7..65f3f44845d 100644
@@ -12,6 +12,7 @@ CONFIG_ENV_OFFSET=0x200
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_agilex_socdk"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffe3f000
 CONFIG_SPL_TEXT_BASE=0xFFE00000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/socfpga_agilex_vab_defconfig +1 -0
index 2883480b30b..b4cfbb0b8a6 100644
@@ -13,6 +13,7 @@ CONFIG_ENV_OFFSET=0x200
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_agilex_socdk"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffe3f000
 CONFIG_SPL_TEXT_BASE=0xFFE00000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/socfpga_arria10_defconfig +1 -0
index 7b3b022d202..71d55e7ede9 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_OFFSET=0x4400
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_arria10_socdk_sdmmc"
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffe2b000
 CONFIG_SPL_TEXT_BASE=0xFFE00000
 CONFIG_TARGET_SOCFPGA_ARRIA10_SOCDK=y
configs/socfpga_arria5_defconfig +1 -0
index 9185af22c61..817452d0873 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_OFFSET=0x4400
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_arria5_socdk"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x0
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_TARGET_SOCFPGA_ARRIA5_SOCDK=y
configs/socfpga_cyclone5_defconfig +1 -0
index 69a9909aa63..c7b9971615d 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_OFFSET=0x4400
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_cyclone5_socdk"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x0
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_TARGET_SOCFPGA_CYCLONE5_SOCDK=y
configs/socfpga_dbm_soc1_defconfig +1 -0
index 5b320e06b4b..68fd6871b76 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_OFFSET=0x4400
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_cyclone5_dbm_soc1"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x0
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_TARGET_SOCFPGA_DEVBOARDS_DBM_SOC1=y
configs/socfpga_de0_nano_soc_defconfig +1 -0
index 04b051cea9a..cfc0f7d3f70 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_OFFSET=0x4400
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_cyclone5_de0_nano_soc"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x0
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_TARGET_SOCFPGA_TERASIC_DE0_NANO=y
configs/socfpga_de10_nano_defconfig +1 -0
index 703af3f9c21..3205d60a67a 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_OFFSET=0x4400
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_cyclone5_de10_nano"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x0
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_TARGET_SOCFPGA_TERASIC_DE10_NANO=y
configs/socfpga_de10_standard_defconfig +1 -0
index 76c41b21cec..97322a7dc5c 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_OFFSET=0x4400
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_cyclone5_de10_standard"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x0
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_TARGET_SOCFPGA_TERASIC_DE10_STANDARD=y
configs/socfpga_de1_soc_defconfig +1 -0
index 8cb158a0150..949c75236ba 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_OFFSET=0x4400
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_cyclone5_de1_soc"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x0
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_TARGET_SOCFPGA_TERASIC_DE1_SOC=y
configs/socfpga_is1_defconfig +1 -0
index 231cf6b47bd..d4c2f3b55e3 100644
@@ -11,6 +11,7 @@ CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_cyclone5_is1"
 CONFIG_DM_RESET=y
 CONFIG_SYS_BOOTCOUNT_ADDR=0xfffffff8
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffff8
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_TARGET_SOCFPGA_IS1=y
configs/socfpga_mcvevk_defconfig +1 -0
index 7aa2db6def0..24ce3f29854 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_OFFSET=0x4400
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_cyclone5_mcvevk"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x0
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_TARGET_SOCFPGA_ARIES_MCVEVK=y
configs/socfpga_n5x_atf_defconfig +1 -0
index 5e927170f21..d7915af4605 100644
@@ -13,6 +13,7 @@ CONFIG_ENV_OFFSET=0x200
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_n5x_socdk"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffe3f000
 CONFIG_SPL_TEXT_BASE=0xFFE00000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/socfpga_n5x_defconfig +1 -0
index 593325c25c3..ba78c343dfe 100644
@@ -12,6 +12,7 @@ CONFIG_ENV_OFFSET=0x200
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_n5x_socdk"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffe3f000
 CONFIG_SPL_TEXT_BASE=0xFFE00000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/socfpga_n5x_vab_defconfig +1 -0
index e3d52fe02e6..487aa95b6fd 100644
@@ -13,6 +13,7 @@ CONFIG_ENV_OFFSET=0x200
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_n5x_socdk"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffe3f000
 CONFIG_SPL_TEXT_BASE=0xFFE00000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/socfpga_secu1_defconfig +1 -0
index dc6d66ade23..5dc084686ce 100644
@@ -13,6 +13,7 @@ CONFIG_DEFAULT_DEVICE_TREE="socfpga_arria5_secu1"
 CONFIG_DM_RESET=y
 # CONFIG_SPL_MMC is not set
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x0
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_SYS_BOOTM_LEN=0x4000000
configs/socfpga_sockit_defconfig +1 -0
index 869ba3d8b79..1ad5162c9e8 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_OFFSET=0x4400
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_cyclone5_sockit"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x0
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_TARGET_SOCFPGA_TERASIC_SOCKIT=y
configs/socfpga_socrates_defconfig +1 -0
index 31b406461e8..0a36e60f61f 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_OFFSET=0x4400
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_cyclone5_socrates"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x0
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_TARGET_SOCFPGA_EBV_SOCRATES=y
configs/socfpga_sr1500_defconfig +1 -0
index cade0d427cd..5e2906a2a16 100644
@@ -12,6 +12,7 @@ CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_cyclone5_sr1500"
 CONFIG_DM_RESET=y
 CONFIG_SYS_BOOTCOUNT_ADDR=0xfffffff8
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffff8
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_TARGET_SOCFPGA_SR1500=y
configs/socfpga_stratix10_atf_defconfig +1 -0
index d3a358c029a..adfdbbbbcc7 100644
@@ -13,6 +13,7 @@ CONFIG_ENV_OFFSET=0x200
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_stratix10_socdk"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffe3f000
 CONFIG_SPL_TEXT_BASE=0xFFE00000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/socfpga_stratix10_defconfig +1 -0
index 3ea82598472..4004b01dcb8 100644
@@ -12,6 +12,7 @@ CONFIG_ENV_OFFSET=0x200
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_stratix10_socdk"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffe3f000
 CONFIG_SPL_TEXT_BASE=0xFFE00000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/socfpga_vining_fpga_defconfig +1 -0
index caecb2a8283..0cd5b00e144 100644
@@ -11,6 +11,7 @@ CONFIG_ENV_SECT_SIZE=0x10000
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="socfpga_cyclone5_vining_fpga"
 CONFIG_DM_RESET=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x0
 CONFIG_SPL_TEXT_BASE=0xFFFF0000
 CONFIG_SYS_BOOTM_LEN=0x2000000
configs/starfive_visionfive2_defconfig +1 -0
index 20f89ae6796..283a54c1e36 100644
@@ -14,6 +14,7 @@ CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_DM_RESET=y
 CONFIG_SPL_MMC=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x8180000
 CONFIG_SPL_TEXT_BASE=0x8000000
 CONFIG_SPL_BSS_START_ADDR=0x8040000
configs/stm32mp15-icore-stm32mp1-ctouch2_defconfig +1 -0
index 4e171200ef2..ce9c1cef31e 100644
@@ -6,6 +6,7 @@ CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0xc0100000
 CONFIG_ENV_OFFSET=0x280000
 CONFIG_DEFAULT_DEVICE_TREE="stm32mp157a-icore-stm32mp1-ctouch2"
 CONFIG_SPL_MMC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x30000000
 CONFIG_SPL_TEXT_BASE=0x2FFC2500
 CONFIG_SYS_BOOTM_LEN=0x2000000
configs/stm32mp15-icore-stm32mp1-edimm2.2_defconfig +1 -0
index 3f7eebd21d8..d02223e242b 100644
@@ -6,6 +6,7 @@ CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0xc0100000
 CONFIG_ENV_OFFSET=0x280000
 CONFIG_DEFAULT_DEVICE_TREE="stm32mp157a-icore-stm32mp1-edimm2.2"
 CONFIG_SPL_MMC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x30000000
 CONFIG_SPL_TEXT_BASE=0x2FFC2500
 CONFIG_SYS_BOOTM_LEN=0x2000000
configs/stm32mp15-microgea-stm32mp1-microdev2-of7_defconfig +1 -0
index b32f71d90eb..650af8b21f9 100644
@@ -6,6 +6,7 @@ CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0xc0100000
 CONFIG_ENV_OFFSET=0x280000
 CONFIG_DEFAULT_DEVICE_TREE="stm32mp157a-microgea-stm32mp1-microdev2.0-of7"
 CONFIG_SPL_MMC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x30000000
 CONFIG_SPL_TEXT_BASE=0x2FFC2500
 CONFIG_SYS_BOOTM_LEN=0x2000000
configs/stm32mp15-microgea-stm32mp1-microdev2_defconfig +1 -0
index 8a16216f926..44dc415ad3b 100644
@@ -6,6 +6,7 @@ CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0xc0100000
 CONFIG_ENV_OFFSET=0x280000
 CONFIG_DEFAULT_DEVICE_TREE="stm32mp157a-microgea-stm32mp1-microdev2.0"
 CONFIG_SPL_MMC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x30000000
 CONFIG_SPL_TEXT_BASE=0x2FFC2500
 CONFIG_SYS_BOOTM_LEN=0x2000000
configs/stm32mp15_basic_defconfig +1 -0
index 1c0d0d0a073..e96ecf130d8 100644
@@ -8,6 +8,7 @@ CONFIG_ENV_SECT_SIZE=0x40000
 CONFIG_SPL_DM_SPI=y
 CONFIG_DEFAULT_DEVICE_TREE="stm32mp157c-ev1"
 CONFIG_SPL_MMC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x30000000
 CONFIG_SPL_TEXT_BASE=0x2FFC2500
 CONFIG_SYS_BOOTM_LEN=0x2000000
configs/stm32mp15_dhsom.config +1 -0
index efc149577ea..cb9c57ab888 100644
@@ -54,6 +54,7 @@ CONFIG_SPL_RAM_DEVICE=y
 CONFIG_SPL_SPI=y
 CONFIG_SPL_SPI_FLASH_MTD=y
 CONFIG_SPL_SPI_FLASH_SUPPORT=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x30000000
 CONFIG_SPL_SYS_MALLOC=y
 CONFIG_SPL_SYS_MALLOC_SIZE=0x1d00000
configs/stout_defconfig +1 -0
index a25a5627c2c..bfa28b1543b 100644
@@ -14,6 +14,7 @@ CONFIG_ARCH_RENESAS_BOARD_STRING="Stout"
 CONFIG_R8A7790=y
 CONFIG_TARGET_STOUT=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xe6340000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x2000
 CONFIG_SPL=y
configs/surface-rt_defconfig +1 -0
index b5c84b4f003..e8d3df73996 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_SOURCE_FILE="surface-rt"
 CONFIG_ENV_SIZE=0x3000
 CONFIG_ENV_OFFSET=0xFFFFD000
 CONFIG_DEFAULT_DEVICE_TREE="tegra30-microsoft-surface-rt"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x82000000
configs/syzygy_hub_defconfig +1 -0
index e7e15c64ba2..8c1a6e7261d 100644
@@ -8,6 +8,7 @@ CONFIG_TEXT_BASE=0x4000000
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="zynq-syzygy-hub"
 CONFIG_SPL_STACK_R_ADDR=0x200000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffe00
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0x100000
configs/taurus_defconfig +1 -0
index b60dfc6cd6f..e6f5dc49b20 100644
@@ -21,6 +21,7 @@ CONFIG_SPL_LDSCRIPT="arch/arm/cpu/u-boot-spl.lds"
 CONFIG_ENV_OFFSET=0x100000
 CONFIG_SPL_DM_SPI=y
 CONFIG_DEFAULT_DEVICE_TREE="at91sam9g20-taurus"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x304000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/tec-ng_defconfig +1 -0
index 5e840ffcf2c..098532a200f 100644
@@ -7,6 +7,7 @@ CONFIG_SF_DEFAULT_SPEED=24000000
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFE000
 CONFIG_DEFAULT_DEVICE_TREE="tegra30-tec-ng"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x81000000
configs/tec_defconfig +1 -0
index 3d46c9e57e3..0bfaa8d8d15 100644
@@ -6,6 +6,7 @@ CONFIG_NR_DRAM_BANKS=2
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0x1FFE0000
 CONFIG_DEFAULT_DEVICE_TREE="tegra20-tec"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffffc
 CONFIG_SPL_TEXT_BASE=0x00108000
 CONFIG_SYS_LOAD_ADDR=0x1000000
configs/theadorable_debug_defconfig +1 -0
index f957167f0ad..5f5f518a8f2 100644
@@ -14,6 +14,7 @@ CONFIG_ENV_OFFSET=0x100000
 CONFIG_ENV_SECT_SIZE=0x40000
 CONFIG_DEFAULT_DEVICE_TREE="armada-xp-theadorable"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40004030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/topic_miami_defconfig +1 -0
index 039ac710b38..84158c3d3b8 100644
@@ -10,6 +10,7 @@ CONFIG_ENV_SIZE=0x8000
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="zynq-topic-miami"
 CONFIG_SPL_STACK_R_ADDR=0x200000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffe00
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0x100000
configs/topic_miamilite_defconfig +1 -0
index b53f3a7150e..7d6d949183e 100644
@@ -10,6 +10,7 @@ CONFIG_ENV_SIZE=0x8000
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="zynq-topic-miamilite"
 CONFIG_SPL_STACK_R_ADDR=0x200000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffe00
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0x100000
configs/topic_miamiplus_defconfig +1 -0
index ba7f248db3b..171c718c3d2 100644
@@ -10,6 +10,7 @@ CONFIG_ENV_SIZE=0x8000
 CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="zynq-topic-miamiplus"
 CONFIG_SPL_STACK_R_ADDR=0x200000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffe00
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0x100000
configs/transformer_t20_defconfig +1 -0
index b69366581a4..e3e771e774c 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_SOURCE_FILE="transformer-t20"
 CONFIG_ENV_SIZE=0x3000
 CONFIG_ENV_OFFSET=0xFFFFD000
 CONFIG_DEFAULT_DEVICE_TREE="tegra20-asus-tf101"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffffc
 CONFIG_SPL_TEXT_BASE=0x00108000
 CONFIG_SYS_LOAD_ADDR=0x2000000
configs/transformer_t30_defconfig +1 -0
index c5f0bc2a613..105b9eab43f 100644
@@ -9,6 +9,7 @@ CONFIG_ENV_SOURCE_FILE="transformer-t30"
 CONFIG_ENV_SIZE=0x3000
 CONFIG_ENV_OFFSET=0xFFFFD000
 CONFIG_DEFAULT_DEVICE_TREE="tegra30-asus-tf201"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x82000000
configs/trimslice_defconfig +1 -0
index c04fc1a7752..c81bdd5f057 100644
@@ -8,6 +8,7 @@ CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFE000
 CONFIG_ENV_SECT_SIZE=0x2000
 CONFIG_DEFAULT_DEVICE_TREE="tegra20-trimslice"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffffc
 CONFIG_SPL_TEXT_BASE=0x00108000
 CONFIG_SYS_LOAD_ADDR=0x1000000
configs/turris_omnia_defconfig +1 -0
index bdcc7407143..d70a1f38873 100644
@@ -20,6 +20,7 @@ CONFIG_ENV_OFFSET=0xF0000
 CONFIG_ENV_SECT_SIZE=0x10000
 CONFIG_DEFAULT_DEVICE_TREE="armada-385-turris-omnia"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40000030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/uniphier_ld4_sld8_defconfig +1 -0
index a0fea87dafd..b9c3a2872ac 100644
@@ -9,6 +9,7 @@ CONFIG_DEFAULT_DEVICE_TREE="uniphier-ld4-ref"
 CONFIG_SYS_MONITOR_LEN=2097152
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x100000
 CONFIG_SPL_TEXT_BASE=0x00040000
 CONFIG_SPL_BSS_MAX_SIZE=0x2000
configs/uniphier_v7_defconfig +1 -0
index 12647bb8ce1..af762523c46 100644
@@ -9,6 +9,7 @@ CONFIG_DEFAULT_DEVICE_TREE="uniphier-pxs2-vodka"
 CONFIG_SYS_MONITOR_LEN=2097152
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x100000
 CONFIG_SPL_TEXT_BASE=0x00100000
 CONFIG_SPL_BSS_MAX_SIZE=0x2000
configs/venice2_defconfig +1 -0
index dfe821b3674..2da6f97b00b 100644
@@ -8,6 +8,7 @@ CONFIG_SF_DEFAULT_SPEED=24000000
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFE000
 CONFIG_DEFAULT_DEVICE_TREE="tegra124-venice2"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x81000000
configs/ventana_defconfig +1 -0
index 1357f5faf26..dbfadae492c 100644
@@ -6,6 +6,7 @@ CONFIG_NR_DRAM_BANKS=2
 CONFIG_ENV_SIZE=0x2000
 CONFIG_ENV_OFFSET=0xFFFFE000
 CONFIG_DEFAULT_DEVICE_TREE="tegra20-ventana"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xffffc
 CONFIG_SPL_TEXT_BASE=0x00108000
 CONFIG_SYS_LOAD_ADDR=0x1000000
configs/verdin-imx8mm_defconfig +1 -0
index b54028f3b60..205cca4e27d 100644
@@ -15,6 +15,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x920000
 CONFIG_SPL_TEXT_BASE=0x7E1000
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/verdin-imx8mp_defconfig +1 -0
index ec76cff4dbe..3458f54adb1 100644
@@ -20,6 +20,7 @@ CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_SPL_MMC=y
 CONFIG_SPL_SERIAL=y
 CONFIG_SPL_DRIVERS_MISC=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x960000
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x4000
 CONFIG_SPL_TEXT_BASE=0x920000
configs/vyasa-rk3288_defconfig +1 -0
index e75466c1cad..3b4dc5b5699 100644
@@ -17,6 +17,7 @@ CONFIG_SYS_MONITOR_LEN=614400
 CONFIG_ROCKCHIP_RK3288=y
 CONFIG_TARGET_VYASA_RK3288=y
 CONFIG_SPL_STACK_R_ADDR=0x80000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xff718000
 CONFIG_SPL_STACK_R=y
 CONFIG_SPL_STACK_R_MALLOC_SIMPLE_LEN=0x2000
configs/work_92105_defconfig +1 -0
index 0b5ad853241..68eeefdf35e 100644
@@ -18,6 +18,7 @@ CONFIG_ENV_SIZE=0x20000
 CONFIG_ENV_OFFSET=0x100000
 CONFIG_SYS_MONITOR_LEN=262144
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfff8
 CONFIG_SPL_TEXT_BASE=0x00000000
 CONFIG_SYS_LOAD_ADDR=0x80008000
configs/x3_t30_defconfig +1 -0
index c8da5b4ce35..25b74e9b48e 100644
@@ -8,6 +8,7 @@ CONFIG_NR_DRAM_BANKS=2
 CONFIG_ENV_SIZE=0x3000
 CONFIG_ENV_OFFSET=0xFFFFD000
 CONFIG_DEFAULT_DEVICE_TREE="tegra30-lg-p880"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x800ffffc
 CONFIG_SPL_TEXT_BASE=0x80108000
 CONFIG_SYS_LOAD_ADDR=0x82000000
configs/x530_defconfig +1 -0
index 89612be631e..1d9e35b71bf 100644
@@ -14,6 +14,7 @@ CONFIG_ENV_OFFSET=0x100000
 CONFIG_ENV_SECT_SIZE=0x40000
 CONFIG_DEFAULT_DEVICE_TREE="armada-385-atl-x530"
 CONFIG_SPL_SERIAL=y
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x4002c000
 CONFIG_SPL_TEXT_BASE=0x40000030
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
configs/xilinx_mbv32_defconfig +1 -0
index 7333413267e..ee7e809946e 100644
@@ -5,6 +5,7 @@ CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
 CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x81200000
 CONFIG_ENV_SIZE=0x20000
 CONFIG_DEFAULT_DEVICE_TREE="xilinx-mbv32"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x80200000
 CONFIG_SPL_BSS_START_ADDR=0x84000000
 CONFIG_SPL_BSS_MAX_SIZE=0x80000
configs/xilinx_mbv32_smode_defconfig +1 -0
index 820681d505b..dcadf33dbbf 100644
@@ -5,6 +5,7 @@ CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
 CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x81200000
 CONFIG_ENV_SIZE=0x20000
 CONFIG_DEFAULT_DEVICE_TREE="xilinx-mbv32"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x80200000
 CONFIG_SPL_BSS_START_ADDR=0x84000000
 CONFIG_SPL_BSS_MAX_SIZE=0x80000
configs/xilinx_mbv64_defconfig +1 -0
index aad9c3f140b..766c55ceed9 100644
@@ -5,6 +5,7 @@ CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
 CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x81200000
 CONFIG_ENV_SIZE=0x20000
 CONFIG_DEFAULT_DEVICE_TREE="xilinx-mbv64"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x80200000
 CONFIG_SPL_BSS_START_ADDR=0x84000000
 CONFIG_SPL_BSS_MAX_SIZE=0x80000
configs/xilinx_mbv64_smode_defconfig +1 -0
index 628e0ed5be2..a5f8076bf4d 100644
@@ -5,6 +5,7 @@ CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
 CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x81200000
 CONFIG_ENV_SIZE=0x20000
 CONFIG_DEFAULT_DEVICE_TREE="xilinx-mbv64"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0x80200000
 CONFIG_SPL_BSS_START_ADDR=0x84000000
 CONFIG_SPL_BSS_MAX_SIZE=0x80000
configs/xilinx_zynq_virt_defconfig +1 -0
index ed3d1019485..126b589b60d 100644
@@ -9,6 +9,7 @@ CONFIG_DM_GPIO=y
 CONFIG_DEFAULT_DEVICE_TREE="zynq-zc706"
 CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_SPL_STACK_R_ADDR=0x200000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffe00
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0x100000
configs/xilinx_zynqmp_kria_defconfig +1 -0
index e5ffc7076fb..e4ad51a39d1 100644
@@ -14,6 +14,7 @@ CONFIG_DEFAULT_DEVICE_TREE="zynqmp-smk-k26-revA"
 CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_DM_RESET=y
 CONFIG_SPL_STACK_R_ADDR=0x18000000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffffc
 CONFIG_SPL_BSS_MAX_SIZE=0x80000
 CONFIG_SPL_STACK_R=y
configs/xilinx_zynqmp_mini_emmc0_defconfig +1 -0
index f47880b6db4..33e4976cf4b 100644
@@ -10,6 +10,7 @@ CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
 CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x10000
 CONFIG_ENV_SIZE=0x80
 CONFIG_DEFAULT_DEVICE_TREE="zynqmp-mini-emmc0"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffffc
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x600
 CONFIG_SPL_BSS_MAX_SIZE=0x80000
configs/xilinx_zynqmp_mini_emmc1_defconfig +1 -0
index fc0070adbe1..80d894bd4fd 100644
@@ -10,6 +10,7 @@ CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
 CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x10000
 CONFIG_ENV_SIZE=0x80
 CONFIG_DEFAULT_DEVICE_TREE="zynqmp-mini-emmc1"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffffc
 CONFIG_SPL_SYS_MALLOC_F_LEN=0x600
 CONFIG_SPL_BSS_MAX_SIZE=0x80000
configs/xilinx_zynqmp_mini_qspi_defconfig +1 -0
index a60403d82c2..706daf0364a 100644
@@ -9,6 +9,7 @@ CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y
 CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0xfffe0000
 CONFIG_ENV_SIZE=0x80
 CONFIG_DEFAULT_DEVICE_TREE="zynqmp-mini-qspi"
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffffc
 CONFIG_SPL_BSS_MAX_SIZE=0x80000
 CONFIG_SYS_LOAD_ADDR=0x8000000
configs/xilinx_zynqmp_virt_defconfig +1 -0
index 310efdf2338..e427f51d9f4 100644
@@ -9,6 +9,7 @@ CONFIG_DEFAULT_DEVICE_TREE="zynqmp-zcu100-revC"
 CONFIG_OF_LIBFDT_OVERLAY=y
 CONFIG_DM_RESET=y
 CONFIG_SPL_STACK_R_ADDR=0x18000000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffffc
 CONFIG_SPL_BSS_MAX_SIZE=0x80000
 CONFIG_SPL_STACK_R=y
configs/zynq_cse_nand_defconfig +1 -0
index 80852f3507d..9afa0a961e9 100644
@@ -11,6 +11,7 @@ CONFIG_SYS_MALLOC_LEN=0x8000
 CONFIG_ENV_SIZE=0x190
 CONFIG_DEFAULT_DEVICE_TREE="zynq-cse-nand"
 CONFIG_SPL_STACK_R_ADDR=0x200000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffe00
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0x20000
configs/zynq_cse_nor_defconfig +1 -0
index 326e4e3f7d1..9fc14303166 100644
@@ -11,6 +11,7 @@ CONFIG_SYS_MALLOC_LEN=0x1000
 CONFIG_ENV_SIZE=0x190
 CONFIG_DEFAULT_DEVICE_TREE="zynq-cse-nor"
 CONFIG_SPL_STACK_R_ADDR=0x200000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffe00
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0x20000
configs/zynq_cse_qspi_defconfig +1 -0
index cd84df1e290..441f665132e 100644
@@ -12,6 +12,7 @@ CONFIG_SF_DEFAULT_SPEED=30000000
 CONFIG_ENV_SIZE=0x190
 CONFIG_DEFAULT_DEVICE_TREE="zynq-cse-qspi-single"
 CONFIG_SPL_STACK_R_ADDR=0x200000
+CONFIG_SPL_HAVE_INIT_STACK=y
 CONFIG_SPL_STACK=0xfffffe00
 CONFIG_SPL_HAS_BSS_LINKER_SECTION=y
 CONFIG_SPL_BSS_START_ADDR=0x20000
Signature · 1 line
2.43.0
#5 lore raw

Re: [PATCH v2 02/35] spl: Add an SPL_HAVE_INIT_STACK option

Hi Simon,

Quoted 5 lines · Simon Glass

At present there is a hex value SPL_STACK which both determines whether SPL has its own initial stack and the hex value of that stack.

Split off the former into SPL_HAVE_INIT_STACK with SPL_STACK depending on that and only providing the latter.

See remark on the name of the symbol in the preceding TPL patch.

Also this and preceding patch should be split out into its own series.

Quoted 245 lines

---

Changes in v2:
- Add new patch with an SPL_HAVE_INIT_STACK option

 arch/arm/cpu/armv7/lowlevel_init.S            |  2 +-
 arch/arm/cpu/armv7/start.S                    |  2 +-
 arch/arm/lib/crt0.S                           |  2 +-
 arch/arm/lib/crt0_64.S                        |  2 +-
 arch/riscv/cpu/start.S                        |  2 +-
 common/spl/Kconfig                            | 28 +++++++++++++++----
 configs/alt_defconfig                         |  1 +
 configs/apalis-tk1_defconfig                  |  1 +
 configs/apalis_t30_defconfig                  |  1 +
 configs/axm_defconfig                         |  1 +
 configs/beaver_defconfig                      |  1 +
 configs/bitmain_antminer_s9_defconfig         |  1 +
 configs/capricorn_cxg3_defconfig              |  1 +
 configs/cardhu_defconfig                      |  1 +
 configs/cei-tk1-som_defconfig                 |  1 +
 configs/cgtqmx8_defconfig                     |  1 +
 configs/chromebit_mickey_defconfig            |  1 +
 configs/chromebook_bob_defconfig              |  1 +
 configs/chromebook_jerry_defconfig            |  1 +
 configs/chromebook_kevin_defconfig            |  1 +
 configs/chromebook_minnie_defconfig           |  1 +
 configs/chromebook_speedy_defconfig           |  1 +
 configs/ci20_mmc_defconfig                    |  1 +
 configs/clearfog_defconfig                    |  1 +
 configs/clearfog_sata_defconfig               |  1 +
 configs/clearfog_spi_defconfig                |  1 +
 configs/colibri_t20_defconfig                 |  1 +
 configs/colibri_t30_defconfig                 |  1 +
 configs/controlcenterdc_defconfig             |  1 +
 configs/corvus_defconfig                      |  1 +
 configs/da850evm_defconfig                    |  1 +
 configs/da850evm_nand_defconfig               |  1 +
 configs/dalmore_defconfig                     |  1 +
 configs/db-88f6720_defconfig                  |  1 +
 configs/db-88f6820-amc_defconfig              |  1 +
 configs/db-88f6820-amc_nand_defconfig         |  1 +
 configs/db-88f6820-gp_defconfig               |  1 +
 configs/db-mv784mp-gp_defconfig               |  1 +
 configs/ds116_defconfig                       |  1 +
 configs/ds414_defconfig                       |  1 +
 configs/endeavoru_defconfig                   |  1 +
 configs/evb-px5_defconfig                     |  1 +
 configs/evb-rk3036_defconfig                  |  1 +
 configs/evb-rk3288_defconfig                  |  1 +
 .../gardena-smart-gateway-at91sam_defconfig   |  1 +
 configs/gose_defconfig                        |  1 +
 configs/grouper_defconfig                     |  1 +
 configs/harmony_defconfig                     |  1 +
 configs/helios4_defconfig                     |  1 +
 configs/ideapad-yoga-11_defconfig             |  1 +
 configs/imx28_xea_defconfig                   |  1 +
 configs/imx8mm-cl-iot-gate-optee_defconfig    |  1 +
 configs/imx8mm-cl-iot-gate_defconfig          |  1 +
 configs/imx8mm-icore-mx8mm-ctouch2_defconfig  |  1 +
 configs/imx8mm-icore-mx8mm-edimm2.2_defconfig |  1 +
 configs/imx8mm-mx8menlo_defconfig             |  1 +
 configs/imx8mm-phygate-tauri-l_defconfig      |  1 +
 configs/imx8mm_beacon_defconfig               |  1 +
 configs/imx8mm_beacon_fspi_defconfig          |  1 +
 configs/imx8mm_data_modul_edm_sbc_defconfig   |  1 +
 configs/imx8mm_evk_defconfig                  |  1 +
 configs/imx8mm_evk_fspi_defconfig             |  1 +
 configs/imx8mm_phg_defconfig                  |  1 +
 configs/imx8mm_venice_defconfig               |  1 +
 configs/imx8mn_beacon_2g_defconfig            |  1 +
 configs/imx8mn_beacon_defconfig               |  1 +
 configs/imx8mn_beacon_fspi_defconfig          |  1 +
 configs/imx8mn_bsh_smm_s2_defconfig           |  1 +
 configs/imx8mn_bsh_smm_s2pro_defconfig        |  1 +
 configs/imx8mn_ddr4_evk_defconfig             |  1 +
 configs/imx8mn_evk_defconfig                  |  1 +
 configs/imx8mn_var_som_defconfig              |  1 +
 configs/imx8mn_venice_defconfig               |  1 +
 configs/imx8mp-icore-mx8mp-edimm2.2_defconfig |  1 +
 configs/imx8mp_beacon_defconfig               |  1 +
 configs/imx8mp_data_modul_edm_sbc_defconfig   |  1 +
 configs/imx8mp_debix_model_a_defconfig        |  1 +
 configs/imx8mp_dhsom.config                   |  1 +
 configs/imx8mp_evk_defconfig                  |  1 +
 configs/imx8mp_navqp_defconfig                |  1 +
 configs/imx8mp_rsb3720a1_4G_defconfig         |  1 +
 configs/imx8mp_rsb3720a1_6G_defconfig         |  1 +
 configs/imx8mp_venice_defconfig               |  1 +
 configs/imx8mq_cm_defconfig                   |  1 +
 configs/imx8mq_evk_defconfig                  |  1 +
 configs/imx8mq_phanbell_defconfig             |  1 +
 configs/imx8mq_reform2_defconfig              |  1 +
 configs/imx8qm_dmsse20a1_defconfig            |  1 +
 configs/imx8qm_mek_defconfig                  |  1 +
 configs/imx8qxp_mek_defconfig                 |  1 +
 configs/imx8ulp_evk_defconfig                 |  1 +
 configs/imx93-phycore_defconfig               |  1 +
 configs/imx93_11x11_evk_defconfig             |  1 +
 configs/imx93_9x9_qsb_defconfig               |  1 +
 configs/imx93_9x9_qsb_inline_ecc_defconfig    |  1 +
 configs/imx93_var_som_defconfig               |  1 +
 configs/jetson-tk1_defconfig                  |  1 +
 configs/k2e_evm_defconfig                     |  1 +
 configs/k2g_evm_defconfig                     |  1 +
 configs/k2hk_evm_defconfig                    |  1 +
 configs/k2l_evm_defconfig                     |  1 +
 configs/koelsch_defconfig                     |  1 +
 configs/kontron-sl-mx8mm_defconfig            |  1 +
 configs/kontron_pitx_imx8m_defconfig          |  1 +
 configs/kontron_sl28_defconfig                |  1 +
 configs/kylin-rk3036_defconfig                |  1 +
 configs/lager_defconfig                       |  1 +
 configs/librem5_defconfig                     |  1 +
 configs/ls1021aiot_sdcard_defconfig           |  1 +
 configs/ls1021aqds_nand_defconfig             |  1 +
 configs/ls1021aqds_sdcard_ifc_defconfig       |  1 +
 configs/ls1021aqds_sdcard_qspi_defconfig      |  1 +
 configs/ls1021atsn_sdcard_defconfig           |  1 +
 ...s1021atwr_sdcard_ifc_SECURE_BOOT_defconfig |  1 +
 configs/ls1021atwr_sdcard_ifc_defconfig       |  1 +
 configs/ls1021atwr_sdcard_qspi_defconfig      |  1 +
 configs/ls2080aqds_nand_defconfig             |  1 +
 configs/ls2080ardb_nand_defconfig             |  1 +
 configs/m53menlo_defconfig                    |  1 +
 configs/maxbcm_defconfig                      |  1 +
 configs/medcom-wide_defconfig                 |  1 +
 configs/microblaze-generic_defconfig          |  1 +
 configs/mk808_defconfig                       |  1 +
 configs/msc_sm2s_imx8mp_defconfig             |  1 +
 configs/mt7629_rfb_defconfig                  |  1 +
 configs/n2350_defconfig                       |  1 +
 configs/nyan-big_defconfig                    |  1 +
 configs/omapl138_lcdk_defconfig               |  1 +
 configs/openpiton_riscv64_spl_defconfig       |  1 +
 configs/paz00_defconfig                       |  1 +
 configs/phycore-imx8mm_defconfig              |  1 +
 configs/phycore-imx8mp_defconfig              |  1 +
 configs/phycore-rk3288_defconfig              |  1 +
 configs/pico-imx8mq_defconfig                 |  1 +
 configs/plutux_defconfig                      |  1 +
 configs/popmetal-rk3288_defconfig             |  1 +
 configs/porter_defconfig                      |  1 +
 configs/qc750_defconfig                       |  1 +
 configs/r8a77970_eagle_defconfig              |  1 +
 configs/r8a77970_v3msk_defconfig              |  1 +
 configs/r8a77980_condor_defconfig             |  1 +
 configs/r8a77980_v3hsk_defconfig              |  1 +
 configs/r8a77990_ebisu_defconfig              |  1 +
 configs/r8a77995_draak_defconfig              |  1 +
 configs/rcar3_salvator-x_defconfig            |  1 +
 configs/rcar3_ulcb_defconfig                  |  1 +
 configs/rock-pi-n8-rk3288_defconfig           |  1 +
 configs/rock2_defconfig                       |  1 +
 configs/rock_defconfig                        |  1 +
 configs/sama5d27_giantboard_defconfig         |  1 +
 configs/sama5d27_som1_ek_mmc1_defconfig       |  1 +
 configs/sama5d27_som1_ek_mmc_defconfig        |  1 +
 configs/sama5d27_som1_ek_qspiflash_defconfig  |  1 +
 configs/sama5d27_wlsom1_ek_mmc_defconfig      |  1 +
 .../sama5d27_wlsom1_ek_qspiflash_defconfig    |  1 +
 configs/sama5d2_icp_mmc_defconfig             |  1 +
 configs/sama5d2_xplained_emmc_defconfig       |  1 +
 configs/sama5d2_xplained_mmc_defconfig        |  1 +
 configs/sama5d2_xplained_qspiflash_defconfig  |  1 +
 configs/sama5d2_xplained_spiflash_defconfig   |  1 +
 configs/sama5d3_xplained_mmc_defconfig        |  1 +
 configs/sama5d3_xplained_nandflash_defconfig  |  1 +
 configs/sama5d3xek_mmc_defconfig              |  1 +
 configs/sama5d3xek_nandflash_defconfig        |  1 +
 configs/sama5d3xek_spiflash_defconfig         |  1 +
 configs/sama5d4_xplained_mmc_defconfig        |  1 +
 configs/sama5d4_xplained_nandflash_defconfig  |  1 +
 configs/sama5d4_xplained_spiflash_defconfig   |  1 +
 configs/sama5d4ek_mmc_defconfig               |  1 +
 configs/sama5d4ek_nandflash_defconfig         |  1 +
 configs/sama5d4ek_spiflash_defconfig          |  1 +
 configs/seaboard_defconfig                    |  1 +
 configs/sifive_unleashed_defconfig            |  1 +
 configs/sifive_unmatched_defconfig            |  1 +
 configs/silinux_ek874_defconfig               |  1 +
 configs/silk_defconfig                        |  1 +
 configs/smartweb_defconfig                    |  1 +
 configs/socfpga_agilex5_defconfig             |  1 +
 configs/socfpga_agilex_atf_defconfig          |  1 +
 configs/socfpga_agilex_defconfig              |  1 +
 configs/socfpga_agilex_vab_defconfig          |  1 +
 configs/socfpga_arria10_defconfig             |  1 +
 configs/socfpga_arria5_defconfig              |  1 +
 configs/socfpga_cyclone5_defconfig            |  1 +
 configs/socfpga_dbm_soc1_defconfig            |  1 +
 configs/socfpga_de0_nano_soc_defconfig        |  1 +
 configs/socfpga_de10_nano_defconfig           |  1 +
 configs/socfpga_de10_standard_defconfig       |  1 +
 configs/socfpga_de1_soc_defconfig             |  1 +
 configs/socfpga_is1_defconfig                 |  1 +
 configs/socfpga_mcvevk_defconfig              |  1 +
 configs/socfpga_n5x_atf_defconfig             |  1 +
 configs/socfpga_n5x_defconfig                 |  1 +
 configs/socfpga_n5x_vab_defconfig             |  1 +
 configs/socfpga_secu1_defconfig               |  1 +
 configs/socfpga_sockit_defconfig              |  1 +
 configs/socfpga_socrates_defconfig            |  1 +
 configs/socfpga_sr1500_defconfig              |  1 +
 configs/socfpga_stratix10_atf_defconfig       |  1 +
 configs/socfpga_stratix10_defconfig           |  1 +
 configs/socfpga_vining_fpga_defconfig         |  1 +
 configs/starfive_visionfive2_defconfig        |  1 +
 ...stm32mp15-icore-stm32mp1-ctouch2_defconfig |  1 +
 ...tm32mp15-icore-stm32mp1-edimm2.2_defconfig |  1 +
 ...-microgea-stm32mp1-microdev2-of7_defconfig |  1 +
 ...mp15-microgea-stm32mp1-microdev2_defconfig |  1 +
 configs/stm32mp15_basic_defconfig             |  1 +
 configs/stm32mp15_dhsom.config                |  1 +
 configs/stout_defconfig                       |  1 +
 configs/surface-rt_defconfig                  |  1 +
 configs/syzygy_hub_defconfig                  |  1 +
 configs/taurus_defconfig                      |  1 +
 configs/tec-ng_defconfig                      |  1 +
 configs/tec_defconfig                         |  1 +
 configs/theadorable_debug_defconfig           |  1 +
 configs/topic_miami_defconfig                 |  1 +
 configs/topic_miamilite_defconfig             |  1 +
 configs/topic_miamiplus_defconfig             |  1 +
 configs/transformer_t20_defconfig             |  1 +
 configs/transformer_t30_defconfig             |  1 +
 configs/trimslice_defconfig                   |  1 +
 configs/turris_omnia_defconfig                |  1 +
 configs/uniphier_ld4_sld8_defconfig           |  1 +
 configs/uniphier_v7_defconfig                 |  1 +
 configs/venice2_defconfig                     |  1 +
 configs/ventana_defconfig                     |  1 +
 configs/verdin-imx8mm_defconfig               |  1 +
 configs/verdin-imx8mp_defconfig               |  1 +
 configs/vyasa-rk3288_defconfig                |  1 +
 configs/work_92105_defconfig                  |  1 +
 configs/x3_t30_defconfig                      |  1 +
 configs/x530_defconfig                        |  1 +
 configs/xilinx_mbv32_defconfig                |  1 +
 configs/xilinx_mbv32_smode_defconfig          |  1 +
 configs/xilinx_mbv64_defconfig                |  1 +
 configs/xilinx_mbv64_smode_defconfig          |  1 +
 configs/xilinx_zynq_virt_defconfig            |  1 +
 configs/xilinx_zynqmp_kria_defconfig          |  1 +
Quoted 8 lines
 configs/xilinx_zynqmp_mini_emmc0_defconfig    |  1 +
 configs/xilinx_zynqmp_mini_emmc1_defconfig    |  1 +
 configs/xilinx_zynqmp_mini_qspi_defconfig     |  1 +
 configs/xilinx_zynqmp_virt_defconfig          |  1 +
 configs/zynq_cse_nand_defconfig               |  1 +
 configs/zynq_cse_nor_defconfig                |  1 +
 configs/zynq_cse_qspi_defconfig               |  1 +
 245 files changed, 267 insertions(+), 10 deletions(-)

This does not seem to apply on top of master or next.

Please do not introduce mass changes in a series targeting a different topic, instead send it as its own series and link and mention it in the cover letter if it's needed for a clean apply.

Regards,
Jonas

#6 lore raw

Re: [PATCH v2 02/35] spl: Add an SPL_HAVE_INIT_STACK option

Hi Jonas,

Quoted 268 lines · Jonas Karlman

Hi Simon,

Quoted 5 lines · Simon Glass

At present there is a hex value SPL_STACK which both determines whether SPL has its own initial stack and the hex value of that stack.

Split off the former into SPL_HAVE_INIT_STACK with SPL_STACK depending on that and only providing the latter.

See remark on the name of the symbol in the preceding TPL patch.

Also this and preceding patch should be split out into its own series.

Quoted 245 lines

---

Changes in v2:
- Add new patch with an SPL_HAVE_INIT_STACK option

 arch/arm/cpu/armv7/lowlevel_init.S            |  2 +-
 arch/arm/cpu/armv7/start.S                    |  2 +-
 arch/arm/lib/crt0.S                           |  2 +-
 arch/arm/lib/crt0_64.S                        |  2 +-
 arch/riscv/cpu/start.S                        |  2 +-
 common/spl/Kconfig                            | 28 +++++++++++++++----
 configs/alt_defconfig                         |  1 +
 configs/apalis-tk1_defconfig                  |  1 +
 configs/apalis_t30_defconfig                  |  1 +
 configs/axm_defconfig                         |  1 +
 configs/beaver_defconfig                      |  1 +
 configs/bitmain_antminer_s9_defconfig         |  1 +
 configs/capricorn_cxg3_defconfig              |  1 +
 configs/cardhu_defconfig                      |  1 +
 configs/cei-tk1-som_defconfig                 |  1 +
 configs/cgtqmx8_defconfig                     |  1 +
 configs/chromebit_mickey_defconfig            |  1 +
 configs/chromebook_bob_defconfig              |  1 +
 configs/chromebook_jerry_defconfig            |  1 +
 configs/chromebook_kevin_defconfig            |  1 +
 configs/chromebook_minnie_defconfig           |  1 +
 configs/chromebook_speedy_defconfig           |  1 +
 configs/ci20_mmc_defconfig                    |  1 +
 configs/clearfog_defconfig                    |  1 +
 configs/clearfog_sata_defconfig               |  1 +
 configs/clearfog_spi_defconfig                |  1 +
 configs/colibri_t20_defconfig                 |  1 +
 configs/colibri_t30_defconfig                 |  1 +
 configs/controlcenterdc_defconfig             |  1 +
 configs/corvus_defconfig                      |  1 +
 configs/da850evm_defconfig                    |  1 +
 configs/da850evm_nand_defconfig               |  1 +
 configs/dalmore_defconfig                     |  1 +
 configs/db-88f6720_defconfig                  |  1 +
 configs/db-88f6820-amc_defconfig              |  1 +
 configs/db-88f6820-amc_nand_defconfig         |  1 +
 configs/db-88f6820-gp_defconfig               |  1 +
 configs/db-mv784mp-gp_defconfig               |  1 +
 configs/ds116_defconfig                       |  1 +
 configs/ds414_defconfig                       |  1 +
 configs/endeavoru_defconfig                   |  1 +
 configs/evb-px5_defconfig                     |  1 +
 configs/evb-rk3036_defconfig                  |  1 +
 configs/evb-rk3288_defconfig                  |  1 +
 .../gardena-smart-gateway-at91sam_defconfig   |  1 +
 configs/gose_defconfig                        |  1 +
 configs/grouper_defconfig                     |  1 +
 configs/harmony_defconfig                     |  1 +
 configs/helios4_defconfig                     |  1 +
 configs/ideapad-yoga-11_defconfig             |  1 +
 configs/imx28_xea_defconfig                   |  1 +
 configs/imx8mm-cl-iot-gate-optee_defconfig    |  1 +
 configs/imx8mm-cl-iot-gate_defconfig          |  1 +
 configs/imx8mm-icore-mx8mm-ctouch2_defconfig  |  1 +
 configs/imx8mm-icore-mx8mm-edimm2.2_defconfig |  1 +
 configs/imx8mm-mx8menlo_defconfig             |  1 +
 configs/imx8mm-phygate-tauri-l_defconfig      |  1 +
 configs/imx8mm_beacon_defconfig               |  1 +
 configs/imx8mm_beacon_fspi_defconfig          |  1 +
 configs/imx8mm_data_modul_edm_sbc_defconfig   |  1 +
 configs/imx8mm_evk_defconfig                  |  1 +
 configs/imx8mm_evk_fspi_defconfig             |  1 +
 configs/imx8mm_phg_defconfig                  |  1 +
 configs/imx8mm_venice_defconfig               |  1 +
 configs/imx8mn_beacon_2g_defconfig            |  1 +
 configs/imx8mn_beacon_defconfig               |  1 +
 configs/imx8mn_beacon_fspi_defconfig          |  1 +
 configs/imx8mn_bsh_smm_s2_defconfig           |  1 +
 configs/imx8mn_bsh_smm_s2pro_defconfig        |  1 +
 configs/imx8mn_ddr4_evk_defconfig             |  1 +
 configs/imx8mn_evk_defconfig                  |  1 +
 configs/imx8mn_var_som_defconfig              |  1 +
 configs/imx8mn_venice_defconfig               |  1 +
 configs/imx8mp-icore-mx8mp-edimm2.2_defconfig |  1 +
 configs/imx8mp_beacon_defconfig               |  1 +
 configs/imx8mp_data_modul_edm_sbc_defconfig   |  1 +
 configs/imx8mp_debix_model_a_defconfig        |  1 +
 configs/imx8mp_dhsom.config                   |  1 +
 configs/imx8mp_evk_defconfig                  |  1 +
 configs/imx8mp_navqp_defconfig                |  1 +
 configs/imx8mp_rsb3720a1_4G_defconfig         |  1 +
 configs/imx8mp_rsb3720a1_6G_defconfig         |  1 +
 configs/imx8mp_venice_defconfig               |  1 +
 configs/imx8mq_cm_defconfig                   |  1 +
 configs/imx8mq_evk_defconfig                  |  1 +
 configs/imx8mq_phanbell_defconfig             |  1 +
 configs/imx8mq_reform2_defconfig              |  1 +
 configs/imx8qm_dmsse20a1_defconfig            |  1 +
 configs/imx8qm_mek_defconfig                  |  1 +
 configs/imx8qxp_mek_defconfig                 |  1 +
 configs/imx8ulp_evk_defconfig                 |  1 +
 configs/imx93-phycore_defconfig               |  1 +
 configs/imx93_11x11_evk_defconfig             |  1 +
 configs/imx93_9x9_qsb_defconfig               |  1 +
 configs/imx93_9x9_qsb_inline_ecc_defconfig    |  1 +
 configs/imx93_var_som_defconfig               |  1 +
 configs/jetson-tk1_defconfig                  |  1 +
 configs/k2e_evm_defconfig                     |  1 +
 configs/k2g_evm_defconfig                     |  1 +
 configs/k2hk_evm_defconfig                    |  1 +
 configs/k2l_evm_defconfig                     |  1 +
 configs/koelsch_defconfig                     |  1 +
 configs/kontron-sl-mx8mm_defconfig            |  1 +
 configs/kontron_pitx_imx8m_defconfig          |  1 +
 configs/kontron_sl28_defconfig                |  1 +
 configs/kylin-rk3036_defconfig                |  1 +
 configs/lager_defconfig                       |  1 +
 configs/librem5_defconfig                     |  1 +
 configs/ls1021aiot_sdcard_defconfig           |  1 +
 configs/ls1021aqds_nand_defconfig             |  1 +
 configs/ls1021aqds_sdcard_ifc_defconfig       |  1 +
 configs/ls1021aqds_sdcard_qspi_defconfig      |  1 +
 configs/ls1021atsn_sdcard_defconfig           |  1 +
 ...s1021atwr_sdcard_ifc_SECURE_BOOT_defconfig |  1 +
 configs/ls1021atwr_sdcard_ifc_defconfig       |  1 +
 configs/ls1021atwr_sdcard_qspi_defconfig      |  1 +
 configs/ls2080aqds_nand_defconfig             |  1 +
 configs/ls2080ardb_nand_defconfig             |  1 +
 configs/m53menlo_defconfig                    |  1 +
 configs/maxbcm_defconfig                      |  1 +
 configs/medcom-wide_defconfig                 |  1 +
 configs/microblaze-generic_defconfig          |  1 +
 configs/mk808_defconfig                       |  1 +
 configs/msc_sm2s_imx8mp_defconfig             |  1 +
 configs/mt7629_rfb_defconfig                  |  1 +
 configs/n2350_defconfig                       |  1 +
 configs/nyan-big_defconfig                    |  1 +
 configs/omapl138_lcdk_defconfig               |  1 +
 configs/openpiton_riscv64_spl_defconfig       |  1 +
 configs/paz00_defconfig                       |  1 +
 configs/phycore-imx8mm_defconfig              |  1 +
 configs/phycore-imx8mp_defconfig              |  1 +
 configs/phycore-rk3288_defconfig              |  1 +
 configs/pico-imx8mq_defconfig                 |  1 +
 configs/plutux_defconfig                      |  1 +
 configs/popmetal-rk3288_defconfig             |  1 +
 configs/porter_defconfig                      |  1 +
 configs/qc750_defconfig                       |  1 +
 configs/r8a77970_eagle_defconfig              |  1 +
 configs/r8a77970_v3msk_defconfig              |  1 +
 configs/r8a77980_condor_defconfig             |  1 +
 configs/r8a77980_v3hsk_defconfig              |  1 +
 configs/r8a77990_ebisu_defconfig              |  1 +
 configs/r8a77995_draak_defconfig              |  1 +
 configs/rcar3_salvator-x_defconfig            |  1 +
 configs/rcar3_ulcb_defconfig                  |  1 +
 configs/rock-pi-n8-rk3288_defconfig           |  1 +
 configs/rock2_defconfig                       |  1 +
 configs/rock_defconfig                        |  1 +
 configs/sama5d27_giantboard_defconfig         |  1 +
 configs/sama5d27_som1_ek_mmc1_defconfig       |  1 +
 configs/sama5d27_som1_ek_mmc_defconfig        |  1 +
 configs/sama5d27_som1_ek_qspiflash_defconfig  |  1 +
 configs/sama5d27_wlsom1_ek_mmc_defconfig      |  1 +
 .../sama5d27_wlsom1_ek_qspiflash_defconfig    |  1 +
 configs/sama5d2_icp_mmc_defconfig             |  1 +
 configs/sama5d2_xplained_emmc_defconfig       |  1 +
 configs/sama5d2_xplained_mmc_defconfig        |  1 +
 configs/sama5d2_xplained_qspiflash_defconfig  |  1 +
 configs/sama5d2_xplained_spiflash_defconfig   |  1 +
 configs/sama5d3_xplained_mmc_defconfig        |  1 +
 configs/sama5d3_xplained_nandflash_defconfig  |  1 +
 configs/sama5d3xek_mmc_defconfig              |  1 +
 configs/sama5d3xek_nandflash_defconfig        |  1 +
 configs/sama5d3xek_spiflash_defconfig         |  1 +
 configs/sama5d4_xplained_mmc_defconfig        |  1 +
 configs/sama5d4_xplained_nandflash_defconfig  |  1 +
 configs/sama5d4_xplained_spiflash_defconfig   |  1 +
 configs/sama5d4ek_mmc_defconfig               |  1 +
 configs/sama5d4ek_nandflash_defconfig         |  1 +
 configs/sama5d4ek_spiflash_defconfig          |  1 +
 configs/seaboard_defconfig                    |  1 +
 configs/sifive_unleashed_defconfig            |  1 +
 configs/sifive_unmatched_defconfig            |  1 +
 configs/silinux_ek874_defconfig               |  1 +
 configs/silk_defconfig                        |  1 +
 configs/smartweb_defconfig                    |  1 +
 configs/socfpga_agilex5_defconfig             |  1 +
 configs/socfpga_agilex_atf_defconfig          |  1 +
 configs/socfpga_agilex_defconfig              |  1 +
 configs/socfpga_agilex_vab_defconfig          |  1 +
 configs/socfpga_arria10_defconfig             |  1 +
 configs/socfpga_arria5_defconfig              |  1 +
 configs/socfpga_cyclone5_defconfig            |  1 +
 configs/socfpga_dbm_soc1_defconfig            |  1 +
 configs/socfpga_de0_nano_soc_defconfig        |  1 +
 configs/socfpga_de10_nano_defconfig           |  1 +
 configs/socfpga_de10_standard_defconfig       |  1 +
 configs/socfpga_de1_soc_defconfig             |  1 +
 configs/socfpga_is1_defconfig                 |  1 +
 configs/socfpga_mcvevk_defconfig              |  1 +
 configs/socfpga_n5x_atf_defconfig             |  1 +
 configs/socfpga_n5x_defconfig                 |  1 +
 configs/socfpga_n5x_vab_defconfig             |  1 +
 configs/socfpga_secu1_defconfig               |  1 +
 configs/socfpga_sockit_defconfig              |  1 +
 configs/socfpga_socrates_defconfig            |  1 +
 configs/socfpga_sr1500_defconfig              |  1 +
 configs/socfpga_stratix10_atf_defconfig       |  1 +
 configs/socfpga_stratix10_defconfig           |  1 +
 configs/socfpga_vining_fpga_defconfig         |  1 +
 configs/starfive_visionfive2_defconfig        |  1 +
 ...stm32mp15-icore-stm32mp1-ctouch2_defconfig |  1 +
 ...tm32mp15-icore-stm32mp1-edimm2.2_defconfig |  1 +
 ...-microgea-stm32mp1-microdev2-of7_defconfig |  1 +
 ...mp15-microgea-stm32mp1-microdev2_defconfig |  1 +
 configs/stm32mp15_basic_defconfig             |  1 +
 configs/stm32mp15_dhsom.config                |  1 +
 configs/stout_defconfig                       |  1 +
 configs/surface-rt_defconfig                  |  1 +
 configs/syzygy_hub_defconfig                  |  1 +
 configs/taurus_defconfig                      |  1 +
 configs/tec-ng_defconfig                      |  1 +
 configs/tec_defconfig                         |  1 +
 configs/theadorable_debug_defconfig           |  1 +
 configs/topic_miami_defconfig                 |  1 +
 configs/topic_miamilite_defconfig             |  1 +
 configs/topic_miamiplus_defconfig             |  1 +
 configs/transformer_t20_defconfig             |  1 +
 configs/transformer_t30_defconfig             |  1 +
 configs/trimslice_defconfig                   |  1 +
 configs/turris_omnia_defconfig                |  1 +
 configs/uniphier_ld4_sld8_defconfig           |  1 +
 configs/uniphier_v7_defconfig                 |  1 +
 configs/venice2_defconfig                     |  1 +
 configs/ventana_defconfig                     |  1 +
 configs/verdin-imx8mm_defconfig               |  1 +
 configs/verdin-imx8mp_defconfig               |  1 +
 configs/vyasa-rk3288_defconfig                |  1 +
 configs/work_92105_defconfig                  |  1 +
 configs/x3_t30_defconfig                      |  1 +
 configs/x530_defconfig                        |  1 +
 configs/xilinx_mbv32_defconfig                |  1 +
 configs/xilinx_mbv32_smode_defconfig          |  1 +
 configs/xilinx_mbv64_defconfig                |  1 +
 configs/xilinx_mbv64_smode_defconfig          |  1 +
 configs/xilinx_zynq_virt_defconfig            |  1 +
 configs/xilinx_zynqmp_kria_defconfig          |  1 +
Quoted 8 lines
 configs/xilinx_zynqmp_mini_emmc0_defconfig    |  1 +
 configs/xilinx_zynqmp_mini_emmc1_defconfig    |  1 +
 configs/xilinx_zynqmp_mini_qspi_defconfig     |  1 +
 configs/xilinx_zynqmp_virt_defconfig          |  1 +
 configs/zynq_cse_nand_defconfig               |  1 +
 configs/zynq_cse_nor_defconfig                |  1 +
 configs/zynq_cse_qspi_defconfig               |  1 +
 245 files changed, 267 insertions(+), 10 deletions(-)
Quoted 1 line

This does not seem to apply on top of master or next.

Yes unfortunately I have my own tree for the moment as too many of my efforts have been blocked. If we get this through review then I can send a rebased series or PR to Tom. If you want to try out a tree, see vbh3 and vbi3

Quoted 4 lines

Please do not introduce mass changes in a series targeting a different topic, instead send it as its own series and link and mention it in the cover letter if it's needed for a clean apply.

OK, well I am 8 series in at this point, so another couple won't make too much difference.

Regards,
Simon

#7 lore raw

PATCH v2 3/35 spl: Use CONFIG_VAL() to obtain the SPL stack

In reply to Simon Glass

Now that we have the same option for SPL and VPL, simplify the logic for determining the initial stack.

---

Changes in v2:
- Add new patch to use CONFIG_VAL() to obtain the SPL stack

 arch/arm/cpu/armv7/lowlevel_init.S | 4 ++--
 arch/arm/cpu/armv7/start.S         | 4 ++--
 arch/arm/lib/crt0.S                | 6 ++----
 arch/arm/lib/crt0_64.S             | 6 ++----
 arch/riscv/cpu/start.S             | 4 ++--
 5 files changed, 10 insertions(+), 14 deletions(-)
arch/arm/cpu/armv7/lowlevel_init.S +2 -2
index c2a0fe061a3..72b7b7d082c 100644
@@ -26,8 +26,8 @@ WEAK(lowlevel_init)
 	/*
 	 * Setup a temporary stack. Global data is not available yet.
 	 */
-#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-	ldr	sp, =CONFIG_SPL_STACK
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+	ldr	sp, =CONFIG_VAL(STACK)
 #else
 	ldr	sp, =SYS_INIT_SP_ADDR
 #endif
arch/arm/cpu/armv7/start.S +2 -2
index 3394db46953..959251957de 100644
@@ -279,8 +279,8 @@ ENTRY(cpu_init_cp15)
 	orr	r2, r4, r2		@ r2 has combined CPU variant + revision
 
 /* Early stack for ERRATA that needs into call C code */
-#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-	ldr	r0, =(CONFIG_SPL_STACK)
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+	ldr	r0, =CONFIG_VAL(STACK)
 #else
 	ldr	r0, =(SYS_INIT_SP_ADDR)
 #endif
arch/arm/lib/crt0.S +2 -4
index 007e89407a8..8ef18ce17e4 100644
@@ -100,10 +100,8 @@ ENTRY(_main)
  * Set up initial C runtime environment and call board_init_f(0).
  */
 
-#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
-	ldr	r0, =(CONFIG_TPL_STACK)
-#elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-	ldr	r0, =(CONFIG_SPL_STACK)
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+	ldr	r0, =CONFIG_VAL(STACK)
 #else
 	ldr	r0, =(SYS_INIT_SP_ADDR)
 #endif
arch/arm/lib/crt0_64.S +2 -4
index 1b6782b06ed..30950ddaf9b 100644
@@ -69,10 +69,8 @@ ENTRY(_main)
 /*
  * Set up initial C runtime environment and call board_init_f(0).
  */
-#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
-	ldr	x0, =(CONFIG_TPL_STACK)
-#elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-	ldr	x0, =(CONFIG_SPL_STACK)
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+	ldr	x0, =CONFIG_VAL(STACK)
 #elif defined(CONFIG_INIT_SP_RELATIVE)
 #if CONFIG_POSITION_INDEPENDENT
 	adrp	x0, __bss_start     /* x0 <- Runtime &__bss_start */
arch/riscv/cpu/start.S +2 -2
index c8526dd82fd..7bafdfd390a 100644
@@ -90,8 +90,8 @@ _start:
  * Set stackpointer in internal/ex RAM to call board_init_f
  */
 call_board_init_f:
-#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-	li	t0, CONFIG_SPL_STACK
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+	li	t0, CONFIG_VAL(STACK)
 #else
 	li	t0, SYS_INIT_SP_ADDR
 #endif
Signature · 1 line
2.43.0
#9 lore raw

Re: [PATCH v2 03/35] spl: Use CONFIG_VAL() to obtain the SPL stack

In reply to Simon Glass

Hi Simon,

Quoted 1 line · Simon Glass

Now that we have the same option for SPL and VPL, simplify the logic for

I suspect you mean TPL here?

Quoted 51 lines

determining the initial stack.

---

Changes in v2:
- Add new patch to use CONFIG_VAL() to obtain the SPL stack

 arch/arm/cpu/armv7/lowlevel_init.S | 4 ++--
 arch/arm/cpu/armv7/start.S         | 4 ++--
 arch/arm/lib/crt0.S                | 6 ++----
 arch/arm/lib/crt0_64.S             | 6 ++----
 arch/riscv/cpu/start.S             | 4 ++--
 5 files changed, 10 insertions(+), 14 deletions(-)
arch/arm/cpu/armv7/lowlevel_init.S +2 -2
index c2a0fe061a3..72b7b7d082c 100644
@@ -26,8 +26,8 @@ WEAK(lowlevel_init)
 	/*
 	 * Setup a temporary stack. Global data is not available yet.
 	 */
-#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-	ldr	sp, =CONFIG_SPL_STACK
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+	ldr	sp, =CONFIG_VAL(STACK)
 #else
 	ldr	sp, =SYS_INIT_SP_ADDR
 #endif
arch/arm/cpu/armv7/start.S +2 -2
index 3394db46953..959251957de 100644
@@ -279,8 +279,8 @@ ENTRY(cpu_init_cp15)
 	orr	r2, r4, r2		@ r2 has combined CPU variant + revision
 
 /* Early stack for ERRATA that needs into call C code */
-#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-	ldr	r0, =(CONFIG_SPL_STACK)
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+	ldr	r0, =CONFIG_VAL(STACK)
 #else
 	ldr	r0, =(SYS_INIT_SP_ADDR)
 #endif
arch/arm/lib/crt0.S +0 -0
index 007e89407a8..8ef18ce17e4 100644

arch/arm/lib/crt0.S ENTRY(_main) · line 104

Quoted 9 lines
arch/arm/lib/crt0.S +2 -4
@@ -100,10 +100,8 @@ ENTRY(_main)
  * Set up initial C runtime environment and call board_init_f(0).
  */
 
-#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
-	ldr	r0, =(CONFIG_TPL_STACK)
-#elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-	ldr	r0, =(CONFIG_SPL_STACK)
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+	ldr	r0, =CONFIG_VAL(STACK)

This changes behavior, prior to this the the SPL_STACK would be fallback for TPL. Now this will only fallback to SYS_INIT_SP_ADDR. Is this intentional and/or will this affect any board?

Quoted 8 lines
arch/arm/lib/crt0.S +0 -0
 #else
 	ldr	r0, =(SYS_INIT_SP_ADDR)
 #endif
arch/arm/lib/crt0_64.S +0 -0
index 1b6782b06ed..30950ddaf9b 100644

arch/arm/lib/crt0_64.S ENTRY(_main) · line 73

Quoted 9 lines
arch/arm/lib/crt0_64.S +2 -4
@@ -69,10 +69,8 @@ ENTRY(_main)
 /*
  * Set up initial C runtime environment and call board_init_f(0).
  */
-#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
-	ldr	x0, =(CONFIG_TPL_STACK)
-#elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-	ldr	x0, =(CONFIG_SPL_STACK)
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+	ldr	x0, =CONFIG_VAL(STACK)

Same here, this changes behavior and should be mentioned in the commit message.

Also this and two preceding patches deserve their own series, especially since this changes behavior.

Regards,
Jonas

Quoted 18 lines
arch/arm/lib/crt0_64.S +0 -0
 #elif defined(CONFIG_INIT_SP_RELATIVE)
 #if CONFIG_POSITION_INDEPENDENT
 	adrp	x0, __bss_start     /* x0 <- Runtime &__bss_start */
arch/riscv/cpu/start.S +2 -2
index c8526dd82fd..7bafdfd390a 100644
@@ -90,8 +90,8 @@ _start:
  * Set stackpointer in internal/ex RAM to call board_init_f
  */
 call_board_init_f:
-#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-	li	t0, CONFIG_SPL_STACK
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+	li	t0, CONFIG_VAL(STACK)
 #else
 	li	t0, SYS_INIT_SP_ADDR
 #endif
#10 lore raw

Re: [PATCH v2 03/35] spl: Use CONFIG_VAL() to obtain the SPL stack

Hi Jonas,

Quoted 7 lines · Jonas Karlman

Hi Simon,

Quoted 1 line · Simon Glass

Now that we have the same option for SPL and VPL, simplify the logic for

I suspect you mean TPL here?

Yes

Quoted 55 lines
Quoted 55 lines

determining the initial stack.

---

Changes in v2:
- Add new patch to use CONFIG_VAL() to obtain the SPL stack

 arch/arm/cpu/armv7/lowlevel_init.S | 4 ++--
 arch/arm/cpu/armv7/start.S         | 4 ++--
 arch/arm/lib/crt0.S                | 6 ++----
 arch/arm/lib/crt0_64.S             | 6 ++----
 arch/riscv/cpu/start.S             | 4 ++--
 5 files changed, 10 insertions(+), 14 deletions(-)
arch/arm/cpu/armv7/lowlevel_init.S +2 -2
index c2a0fe061a3..72b7b7d082c 100644
@@ -26,8 +26,8 @@ WEAK(lowlevel_init)
      /*
       * Setup a temporary stack. Global data is not available yet.
       */
-#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-     ldr     sp, =CONFIG_SPL_STACK
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+     ldr     sp, =CONFIG_VAL(STACK)
 #else
      ldr     sp, =SYS_INIT_SP_ADDR
 #endif
arch/arm/cpu/armv7/start.S +2 -2
index 3394db46953..959251957de 100644
@@ -279,8 +279,8 @@ ENTRY(cpu_init_cp15)
      orr     r2, r4, r2              @ r2 has combined CPU variant + revision
 
 /* Early stack for ERRATA that needs into call C code */
-#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-     ldr     r0, =(CONFIG_SPL_STACK)
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+     ldr     r0, =CONFIG_VAL(STACK)
 #else
      ldr     r0, =(SYS_INIT_SP_ADDR)
 #endif
arch/arm/lib/crt0.S +0 -0
index 007e89407a8..8ef18ce17e4 100644
@@ -100,10 +100,8 @@ ENTRY(_main)
  * Set up initial C runtime environment and call board_init_f(0).
  */
 
Quoted 10 lines

arch/arm/lib/crt0.S ENTRY(_main) · line 104

Quoted 6 lines
arch/arm/lib/crt0.S +2 -4
-#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
-     ldr     r0, =(CONFIG_TPL_STACK)
-#elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-     ldr     r0, =(CONFIG_SPL_STACK)
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+     ldr     r0, =CONFIG_VAL(STACK)

This changes behavior, prior to this the the SPL_STACK would be fallback for TPL. Now this will only fallback to SYS_INIT_SP_ADDR. Is this intentional and/or will this affect any board?

I didn't see that, actually. But I think it is a bug, so yes my change is intentional. I'll update the commit message.

Quoted 22 lines
Quoted 9 lines
arch/arm/lib/crt0.S +0 -0
 #else
      ldr     r0, =(SYS_INIT_SP_ADDR)
 #endif
arch/arm/lib/crt0_64.S +0 -0
index 1b6782b06ed..30950ddaf9b 100644

arch/arm/lib/crt0_64.S ENTRY(_main) · line 73

Quoted 9 lines
arch/arm/lib/crt0_64.S +2 -4
@@ -69,10 +69,8 @@ ENTRY(_main)
 /*
  * Set up initial C runtime environment and call board_init_f(0).
  */
-#if defined(CONFIG_TPL_BUILD) && defined(CONFIG_TPL_HAVE_INIT_STACK)
-     ldr     x0, =(CONFIG_TPL_STACK)
-#elif defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-     ldr     x0, =(CONFIG_SPL_STACK)
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+     ldr     x0, =CONFIG_VAL(STACK)

Same here, this changes behavior and should be mentioned in the commit message.

Quoted 2 lines

Also this and two preceding patches deserve their own series, especially since this changes behavior.

OK

Quoted 14 lines

Regards,
Jonas

Quoted 10 lines
arch/arm/lib/crt0_64.S +0 -0
 #elif defined(CONFIG_INIT_SP_RELATIVE)
 #if CONFIG_POSITION_INDEPENDENT
      adrp    x0, __bss_start     /* x0 <- Runtime &__bss_start */
arch/riscv/cpu/start.S +0 -0
index c8526dd82fd..7bafdfd390a 100644
@@ -90,8 +90,8 @@ _start:
  * Set stackpointer in internal/ex RAM to call board_init_f
  */
Quoted 9 lines

arch/riscv/cpu/start.S _start: · line 97

Quoted 8 lines
arch/riscv/cpu/start.S +2 -2
 call_board_init_f:
-#if defined(CONFIG_XPL_BUILD) && defined(CONFIG_SPL_HAVE_INIT_STACK)
-     li      t0, CONFIG_SPL_STACK
+#if CONFIG_IS_ENABLED(HAVE_INIT_STACK)
+     li      t0, CONFIG_VAL(STACK)
 #else
      li      t0, SYS_INIT_SP_ADDR
 #endif

Regards,
Simon

#11 lore raw

PATCH v2 4/35 arm: Support a separate stack for VPL

In reply to Simon Glass

VPL has the same needs as TPL in situations where the stack is at the top of SRAM. Add an option for this and implement it for arm

---

Changes in v2:
- Reply on existing CONFIG_VAL() to select the VPL stack
- Correct reference to TPL when VPL was intended

 common/spl/Kconfig.vpl | 14 ++++++++++++++
 1 file changed, 14 insertions(+)
common/spl/Kconfig.vpl +14 -0
index cf6b36c8e38..4abb96221bb 100644
@@ -266,6 +266,20 @@ config VPL_MAX_SIZE
 	  The maximum size (in bytes) of the TPL stage. This size is determined
 	  by the amount of internal SRAM memory.
 
+config VPL_HAVE_INIT_STACK
+	bool "VPL requires a initial, fixed, stack-pointer location"
+	help
+	  Enable if the VPL phase should not use inherit its initial
+	  stack-pointer from the settings for U-Boot proper, but should set
+	  its own value.
+
+config VPL_STACK
+	hex "Address of the initial stack-pointer for the VPL stage"
+	depends on VPL_HAVE_INIT_STACK
+	help
+	  The address of the initial stack-pointer for the VPL stage.
+	  Usually this will be the (aligned) top-of-stack.
+
 config VPL_BINMAN_SYMBOLS
 	bool "Declare binman symbols in VPL"
 	depends on VPL_FRAMEWORK && BINMAN
Signature · 1 line
2.43.0
#12 lore raw

Re: [PATCH v2 04/35] arm: Support a separate stack for VPL

Hi Simon,

Quoted 18 lines · Simon Glass

VPL has the same needs as TPL in situations where the stack is at the top of SRAM. Add an option for this and implement it for arm

---

Changes in v2:
- Reply on existing CONFIG_VAL() to select the VPL stack
- Correct reference to TPL when VPL was intended

 common/spl/Kconfig.vpl | 14 ++++++++++++++
 1 file changed, 14 insertions(+)
common/spl/Kconfig.vpl +0 -0
index cf6b36c8e38..4abb96221bb 100644

common/spl/Kconfig.vpl config VPL_MAX_SIZE · line 269

Quoted 4 lines
common/spl/Kconfig.vpl +1 -0
@@ -266,6 +266,20 @@ config VPL_MAX_SIZE
 	  The maximum size (in bytes) of the TPL stage. This size is determined
 	  by the amount of internal SRAM memory.
 
+config VPL_HAVE_INIT_STACK

Please see my remark on the name from the TPL patch.

common/spl/Kconfig.vpl config VPL_MAX_SIZE · line 281

Quoted 12 lines
common/spl/Kconfig.vpl +12 -0
+	bool "VPL requires a initial, fixed, stack-pointer location"
+	help
+	  Enable if the VPL phase should not use inherit its initial
+	  stack-pointer from the settings for U-Boot proper, but should set
+	  its own value.
+
+config VPL_STACK
+	hex "Address of the initial stack-pointer for the VPL stage"
+	depends on VPL_HAVE_INIT_STACK
+	help
+	  The address of the initial stack-pointer for the VPL stage.
+	  Usually this will be the (aligned) top-of-stack.

Here you are using stage, when you changed it to phase for TPL and use phase for the above symbol, please be consistent.

As already mentioned, please split patch 1-4 into a separate series.

Regards,
Jonas

Quoted 4 lines
common/spl/Kconfig.vpl +1 -0
+
 config VPL_BINMAN_SYMBOLS
 	bool "Declare binman symbols in VPL"
 	depends on VPL_FRAMEWORK && BINMAN
#13 lore raw

Re: [PATCH v2 04/35] arm: Support a separate stack for VPL

Hi Jonas,

Quoted 25 lines · Jonas Karlman

Hi Simon,

Quoted 21 lines · Simon Glass

VPL has the same needs as TPL in situations where the stack is at the top of SRAM. Add an option for this and implement it for arm

---

Changes in v2:
- Reply on existing CONFIG_VAL() to select the VPL stack
- Correct reference to TPL when VPL was intended

 common/spl/Kconfig.vpl | 14 ++++++++++++++
 1 file changed, 14 insertions(+)
common/spl/Kconfig.vpl +0 -0
index cf6b36c8e38..4abb96221bb 100644
@@ -266,6 +266,20 @@ config VPL_MAX_SIZE
        The maximum size (in bytes) of the TPL stage. This size is determined
        by the amount of internal SRAM memory.
 
Quoted 3 lines

common/spl/Kconfig.vpl config VPL_MAX_SIZE · line 269

Quoted 1 line
common/spl/Kconfig.vpl +1 -0
+config VPL_HAVE_INIT_STACK

Please see my remark on the name from the TPL patch.

Yes I replied to that.

Quoted 17 lines

common/spl/Kconfig.vpl config VPL_MAX_SIZE · line 281

Quoted 13 lines
common/spl/Kconfig.vpl +12 -0
+     bool "VPL requires a initial, fixed, stack-pointer location"
+     help
+       Enable if the VPL phase should not use inherit its initial
+       stack-pointer from the settings for U-Boot proper, but should set
+       its own value.
+
+config VPL_STACK
+     hex "Address of the initial stack-pointer for the VPL stage"
+     depends on VPL_HAVE_INIT_STACK
+     help
+       The address of the initial stack-pointer for the VPL stage.
+       Usually this will be the (aligned) top-of-stack.

Here you are using stage, when you changed it to phase for TPL and use phase for the above symbol, please be consistent.

Quoted 1 line

As already mentioned, please split patch 1-4 into a separate series.

OK

Quoted 9 lines

Regards,
Jonas

Quoted 4 lines
common/spl/Kconfig.vpl +1 -0
+
 config VPL_BINMAN_SYMBOLS
      bool "Declare binman symbols in VPL"
      depends on VPL_FRAMEWORK && BINMAN

Regards,
Simon

#14 lore raw

PATCH v2 5/35 spl: Adjust xPL symbols

In reply to Simon Glass

Update for the new xPL naming, which was missed in a previous patch which purported to do this.

---

(no changes since v1)

 common/spl/spl_reloc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
common/spl/spl_reloc.c +1 -1
index 324b98eaf98..216c0f36623 100644
@@ -59,7 +59,7 @@ static int setup_layout(struct spl_image_info *image, ulong *addrp)
 	uint need_size = image->size + image->fdt_size;
 	margin = buf_size - need_size;
 	log_debug("spl_reloc %s->%s: margin%s%lx limit %lx fdt_size %lx base %lx avail %x image %x fdt %lx need %x\n",
-		  spl_phase_name(spl_phase()), spl_phase_name(spl_phase() + 1),
+		  xpl_name(xpl_phase()), xpl_name(xpl_phase() + 1),
 		  margin >= 0 ? " " : " -", abs(margin), limit, fdt_size, base,
 		  buf_size, image->size, image->fdt_size, need_size);
 	if (margin < 0) {
Signature · 1 line
2.43.0
#15 lore raw

PATCH v2 6/35 spl: Allow VBE to handle xPL size

In reply to Simon Glass

When VBE is in use, the size of each phase is obtained by reading it from a FIT. Avoid using binman symbols unless necessary, i.e. in TPL.

---

(no changes since v1)

 common/spl/spl.c | 2 ++
 1 file changed, 2 insertions(+)
common/spl/spl.c +2 -0
index 6b75910e243..e7157df1ff9 100644
@@ -200,6 +200,8 @@ ulong spl_get_image_size(void)
 #ifdef CONFIG_VPL
 	if (xpl_next_phase() == PHASE_VPL)
 		return binman_sym(ulong, u_boot_vpl_any, size);
+
+	return 0;	/* VBE handles this */
 #endif
 	return xpl_next_phase() == PHASE_SPL ?
 		binman_sym(ulong, u_boot_spl_any, size) :
Signature · 1 line
2.43.0
#16 lore raw

PATCH v2 7/35 vbe: Show the margin when using SPL_RELOC

In reply to Simon Glass

Collect information about the memory-margin in each phase which uses this feature. Update the 'vbe state' command to show it.

---

(no changes since v1)

 cmd/vbe.c              |  8 ++++++--
 common/spl/spl_reloc.c | 12 ++++++++++++
 include/vbe.h          |  3 +++
 3 files changed, 21 insertions(+), 2 deletions(-)
cmd/vbe.c +6 -2
index 186f6e6860d..02d224ad286 100644
@@ -92,9 +92,13 @@ static int do_vbe_state(struct cmd_tbl *cmdtp, int flag, int argc,
 
 	printf("Phases:");
 	for (i = PHASE_NONE; i < PHASE_COUNT; i++) {
-		if (handoff->phases & (1 << i))
-			printf(" %s", xpl_name(i));
+		if (handoff->phases & (1 << i)) {
+			int margin = handoff->reloc_margin[i];
 
+			printf(" %s", xpl_name(i));
+			if (margin)
+				printf(" (margin %x) ", margin);
+		}
 	}
 	if (!handoff->phases)
 		printf(" (none)");
common/spl/spl_reloc.c +12 -0
index 216c0f36623..6bfc75bc484 100644
@@ -4,11 +4,13 @@
  * Written by Simon Glass <[email protected]>
  */
 
+#include <bloblist.h>
 #include <gzip.h>
 #include <image.h>
 #include <log.h>
 #include <mapmem.h>
 #include <spl.h>
+#include <vbe.h>
 #include <asm/global_data.h>
 #include <asm/io.h>
 #include <asm/sections.h>
@@ -58,6 +60,16 @@ static int setup_layout(struct spl_image_info *image, ulong *addrp)
 	buf_size = rcode_base - base;
 	uint need_size = image->size + image->fdt_size;
 	margin = buf_size - need_size;
+
+	if (CONFIG_IS_ENABLED(BLOBLIST)) {
+		struct vbe_handoff *handoff;
+
+		handoff = bloblist_find(BLOBLISTT_VBE,
+					sizeof(struct vbe_handoff));
+		if (handoff)
+			handoff->reloc_margin[xpl_phase()] = margin;
+	}
+
 	log_debug("spl_reloc %s->%s: margin%s%lx limit %lx fdt_size %lx base %lx avail %x image %x fdt %lx need %x\n",
 		  xpl_name(xpl_phase()), xpl_name(xpl_phase() + 1),
 		  margin >= 0 ? " " : " -", abs(margin), limit, fdt_size, base,
include/vbe.h +3 -0
index 61bfa0e557d..84a996cdf7f 100644
@@ -11,6 +11,7 @@
 #define __VBE_H
 
 #include <linux/types.h>
+#include <spl.h>
 
 /**
  * enum vbe_phase_t - current phase of VBE
@@ -47,12 +48,14 @@ enum vbe_pick_t {
  * @size: Size of the area containing the FIT
  * @phases: Indicates which phases used the VBE bootmeth (1 << PHASE_...)
  * @pick: Indicates which firmware pick was used (enum vbe_pick_t)
+ * @reloc_margin: Indicates the number of bytes of margin coming into this phase
  */
 struct vbe_handoff {
 	ulong offset;
 	ulong size;
 	u8 phases;
 	u8 pick;
+	int reloc_margin[PHASE_COUNT];
 };
 
 /**
Signature · 1 line
2.43.0
#17 lore raw

PATCH v2 8/35 rockchip: Allow RAM init to happen in SPL on rk3399

In reply to Simon Glass

TPL runs before VPL. The earliest updatable phase with VBE is SPL. We want to be able to update the RAM-init code in the field.

So when VPL is being used, init the RAM later, in SPL.

---

(no changes since v1)

 drivers/ram/rockchip/sdram_rk3399.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
drivers/ram/rockchip/sdram_rk3399.c +4 -2
index 6fa8f268770..9ac16dfdc71 100644
@@ -194,6 +194,7 @@ struct io_setting {
 static bool phase_sdram_init(void)
 {
 	return xpl_phase() == PHASE_TPL ||
+		(IS_ENABLED(CONFIG_VPL) && xpl_phase() == PHASE_SPL) ||
 		(!IS_ENABLED(CONFIG_TPL) &&
 		 !IS_ENABLED(CONFIG_ROCKCHIP_EXTERNAL_TPL) &&
 		 !not_xpl());
@@ -3195,8 +3196,9 @@ U_BOOT_DRIVER(dmc_rk3399) = {
 	.of_to_plat = rk3399_dmc_of_to_plat,
 	.probe = rk3399_dmc_probe,
 	.priv_auto	= sizeof(struct dram_info),
-#if defined(CONFIG_TPL_BUILD) || \
-	(!defined(CONFIG_TPL) && defined(CONFIG_XPL_BUILD))
+#if defined(CONFIG_VPL) && defined(CONFIG_SPL_BUILD) || \
+	!defined(CONFIG_VPL) && defined(CONFIG_TPL_BUILD) || \
+	!defined(CONFIG_TPL) && defined(CONFIG_SPL_BUILD)
 	.plat_auto	= sizeof(struct rockchip_dmc_plat),
 #endif
 };
Signature · 1 line
2.43.0
#18 lore raw

PATCH v2 9/35 rockchip: dts: Correct the OS for U-Boot

In reply to Simon Glass

The U-Boot section is currently getting an invalid OS. Use the correct value to fix this.

---

Changes in v2:
- Put this patch before 'Factor out arch and compression'

 arch/arm/dts/rockchip-u-boot.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/dts/rockchip-u-boot.dtsi +1 -1
index c8c928c7e50..e9ed1d4b573 100644
@@ -50,7 +50,7 @@
 				u-boot {
 					description = "U-Boot";
 					type = "standalone";
-					os = "U-Boot";
+					os = "u-boot";
 #ifdef CONFIG_ARM64
 					arch = "arm64";
 #else
Signature · 1 line
2.43.0
#19 lore raw

PATCH v2 10/35 rockchip: dts: Factor out arch and compression

In reply to Simon Glass

Declare these at the top of the file to avoid needing #ifdefs in every usage.

Add a few comments to help with the remaining #ifdefs

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 44 +++++++++++++++----------------
 1 file changed, 22 insertions(+), 22 deletions(-)
arch/arm/dts/rockchip-u-boot.dtsi +22 -22
index e9ed1d4b573..2b01dc66056 100644
@@ -5,6 +5,20 @@
 
 #include <config.h>
 
+#ifdef CONFIG_ARM64
+#define ARCH	"arm64"
+#else
+#define ARCH	"arm"
+#endif
+
+#if defined(CONFIG_SPL_GZIP)
+#define COMP	"gzip"
+#elif defined(CONFIG_SPL_LZMA)
+#define COMP	"lzma"
+#else
+#define COMP	"none"
+#endif
+
 / {
 	binman: binman {
 		multiple-images;
@@ -51,26 +65,12 @@
 					description = "U-Boot";
 					type = "standalone";
 					os = "u-boot";
-#ifdef CONFIG_ARM64
-					arch = "arm64";
-#else
-					arch = "arm";
-#endif
-#if defined(CONFIG_SPL_GZIP)
-					compression = "gzip";
-#elif defined(CONFIG_SPL_LZMA)
-					compression = "lzma";
-#else
-					compression = "none";
-#endif
+					arch = ARCH;
+					compression = COMP;
 					load = <CONFIG_TEXT_BASE>;
 					entry = <CONFIG_TEXT_BASE>;
 					u-boot-nodtb {
-#if defined(CONFIG_SPL_GZIP)
-					compress = "gzip";
-#elif defined(CONFIG_SPL_LZMA)
-					compress = "lzma";
-#endif
+					compress = COMP;
 					};
 #ifdef CONFIG_SPL_FIT_SIGNATURE
 					hash {
@@ -84,7 +84,7 @@
 					fit,operation = "split-elf";
 					description = "ARM Trusted Firmware";
 					type = "firmware";
-					arch = "arm64";
+					arch = ARCH;
 					os = "arm-trusted-firmware";
 					compression = "none";
 					fit,load;
@@ -103,7 +103,7 @@
 					fit,operation = "split-elf";
 					description = "TEE";
 					type = "tee";
-					arch = "arm64";
+					arch = ARCH;
 					os = "tee";
 					compression = "none";
 					fit,load;
@@ -119,11 +119,11 @@
 					};
 #endif
 				};
-#else
+#else /* !CONFIG_ARM64 */
 				op-tee {
 					description = "OP-TEE";
 					type = "tee";
-					arch = "arm";
+					arch = ARCH;
 					os = "tee";
 					compression = "none";
 					load = <(CFG_SYS_SDRAM_BASE + 0x8400000)>;
@@ -137,7 +137,7 @@
 					};
 #endif
 				};
-#endif
+#endif /* CONFIG_ARM64 */
 
 				@fdt-SEQ {
 					description = "fdt-NAME";
Signature · 1 line
2.43.0
#20 lore raw

PATCH v2 11/35 rockchip: dts: Add an fdtmap

In reply to Simon Glass

Add an fdtmap so it is possible to look at the image with 'binman ls'.

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 4 ++++
 1 file changed, 4 insertions(+)
arch/arm/dts/rockchip-u-boot.dtsi +4 -0
index 2b01dc66056..64a6b57d5fd 100644
@@ -170,6 +170,8 @@
 			offset = <CONFIG_SPL_PAD_TO>;
 		};
 #endif
+		fdtmap {
+		};
 	};
 
 #ifdef CONFIG_ROCKCHIP_SPI_IMAGE
@@ -203,6 +205,8 @@
 			/* Sync with u-boot,spl-payload-offset if present */
 			offset = <CONFIG_SYS_SPI_U_BOOT_OFFS>;
 		};
+		fdtmap {
+		};
 	};
 #endif /* CONFIG_ROCKCHIP_SPI_IMAGE */
 };
Signature · 1 line
2.43.0
Reviewed-by on v2 11/35
#21 lore raw

Re: [PATCH v2 11/35] rockchip: dts: Add an fdtmap

Hi Simon,

Quoted 15 lines · Simon Glass

Add an fdtmap so it is possible to look at the image with 'binman ls'.

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 4 ++++
 1 file changed, 4 insertions(+)
arch/arm/dts/rockchip-u-boot.dtsi +0 -0
index 2b01dc66056..64a6b57d5fd 100644

arch/arm/dts/rockchip-u-boot.dtsi line 172

Quoted 3 lines
arch/arm/dts/rockchip-u-boot.dtsi +0 -0
@@ -170,6 +170,8 @@
 			offset = <CONFIG_SPL_PAD_TO>;
 		};
 #endif

Nitpick:

The Linux Devicetree Sources (DTS) Coding Style [1] recommend that each child node is preceded with a blank line.

Please add blank line before the fdtmap node here.

[1] https://docs.kernel.org/devicetree/bindings/dts-coding-style.html#order-of-properties-in-device-node

arch/arm/dts/rockchip-u-boot.dtsi line 207

Quoted 9 lines
arch/arm/dts/rockchip-u-boot.dtsi +2 -0
+		fdtmap {
+		};
 	};
 
 #ifdef CONFIG_ROCKCHIP_SPI_IMAGE
@@ -203,6 +205,8 @@
 			/* Sync with u-boot,spl-payload-offset if present */
 			offset = <CONFIG_SYS_SPI_U_BOOT_OFFS>;
 		};

Same here.

With that fixed this is:

Regards,
Jonas

Quoted 5 lines
arch/arm/dts/rockchip-u-boot.dtsi +2 -0
+		fdtmap {
+		};
 	};
 #endif /* CONFIG_ROCKCHIP_SPI_IMAGE */
 };
#22 lore raw

PATCH v2 12/35 rockchip: dts: Create a template for the FIT

In reply to Simon Glass

Move the FIT description into a template so that it can (later) be used in multiple places in the image.

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 57 ++++++++++++++++++-------------
 1 file changed, 34 insertions(+), 23 deletions(-)
arch/arm/dts/rockchip-u-boot.dtsi +34 -23
index 64a6b57d5fd..ca666ba0cd4 100644
@@ -19,6 +19,10 @@
 #define COMP	"none"
 #endif
 
+#if defined(CONFIG_SPL_FIT) && (defined(CONFIG_ARM64) || defined(CONFIG_SPL_OPTEE_IMAGE))
+#define HAS_FIT
+#endif
+
 / {
 	binman: binman {
 		multiple-images;
@@ -27,28 +31,9 @@
 
 #ifdef CONFIG_SPL
 &binman {
-	simple-bin {
-		filename = "u-boot-rockchip.bin";
-		pad-byte = <0xff>;
-
-		mkimage {
-			filename = "idbloader.img";
-			args = "-n", CONFIG_SYS_SOC, "-T", "rksd";
-			multiple-data-files;
-
-#ifdef CONFIG_ROCKCHIP_EXTERNAL_TPL
-			rockchip-tpl {
-			};
-#elif defined(CONFIG_TPL)
-			u-boot-tpl {
-			};
-#endif
-			u-boot-spl {
-			};
-		};
-
-#if defined(CONFIG_SPL_FIT) && (defined(CONFIG_ARM64) || defined(CONFIG_SPL_OPTEE_IMAGE))
-		fit: fit {
+#ifdef HAS_FIT
+	common_part: template-1 {
+			type = "fit";
 #ifdef CONFIG_ARM64
 			description = "FIT image for U-Boot with bl31 (TF-A)";
 #else
@@ -59,7 +44,6 @@
 			filename = "u-boot.itb";
 			fit,external-offset = <CONFIG_FIT_EXTERNAL_OFFSET>;
 			fit,align = <512>;
-			offset = <CONFIG_SPL_PAD_TO>;
 			images {
 				u-boot {
 					description = "U-Boot";
@@ -164,6 +148,33 @@
 					fit,loadables;
 				};
 			};
+	};
+#endif /* HAS_FIT */
+
+	simple-bin {
+		filename = "u-boot-rockchip.bin";
+		pad-byte = <0xff>;
+
+		mkimage {
+			filename = "idbloader.img";
+			args = "-n", CONFIG_SYS_SOC, "-T", "rksd";
+			multiple-data-files;
+
+#ifdef CONFIG_ROCKCHIP_EXTERNAL_TPL
+			rockchip-tpl {
+			};
+#elif defined(CONFIG_TPL)
+			u-boot-tpl {
+			};
+#endif
+			u-boot-spl {
+			};
+		};
+
+#ifdef HAS_FIT
+		fit {
+			offset = <CONFIG_SPL_PAD_TO>;
+			insert-template = <&common_part>;
 		};
 #else
 		u-boot-img {
Signature · 1 line
2.43.0
Reviewed-by on v2 12/35
#23 lore raw

Re: [PATCH v2 12/35] rockchip: dts: Create a template for the FIT

Hi Simon,

Quoted 59 lines · Simon Glass

Move the FIT description into a template so that it can (later) be used in multiple places in the image.

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 57 ++++++++++++++++++-------------
 1 file changed, 34 insertions(+), 23 deletions(-)
arch/arm/dts/rockchip-u-boot.dtsi +7 -22
index 64a6b57d5fd..ca666ba0cd4 100644
@@ -19,6 +19,10 @@
 #define COMP	"none"
 #endif
 
+#if defined(CONFIG_SPL_FIT) && (defined(CONFIG_ARM64) || defined(CONFIG_SPL_OPTEE_IMAGE))
+#define HAS_FIT
+#endif
+
 / {
 	binman: binman {
 		multiple-images;
@@ -27,28 +31,9 @@
 
 #ifdef CONFIG_SPL
 &binman {
-	simple-bin {
-		filename = "u-boot-rockchip.bin";
-		pad-byte = <0xff>;
-
-		mkimage {
-			filename = "idbloader.img";
-			args = "-n", CONFIG_SYS_SOC, "-T", "rksd";
-			multiple-data-files;
-
-#ifdef CONFIG_ROCKCHIP_EXTERNAL_TPL
-			rockchip-tpl {
-			};
-#elif defined(CONFIG_TPL)
-			u-boot-tpl {
-			};
-#endif
-			u-boot-spl {
-			};
-		};
-
-#if defined(CONFIG_SPL_FIT) && (defined(CONFIG_ARM64) || defined(CONFIG_SPL_OPTEE_IMAGE))
-		fit: fit {
+#ifdef HAS_FIT
+	common_part: template-1 {
+			type = "fit";
 #ifdef CONFIG_ARM64
 			description = "FIT image for U-Boot with bl31 (TF-A)";
 #else

arch/arm/dts/rockchip-u-boot.dtsi line 44

Quoted 1 line
arch/arm/dts/rockchip-u-boot.dtsi +0 -0
@@ -59,7 +44,6 @@
 			filename = "u-boot.itb";

Please move the filename prop to the fit node in this patch.

There are lots of guides and Linux image building scripts that depend on the u-boot.itb file, so we should continue to keep this file to be backward compatible for a few more releases.

Quoted 30 lines
arch/arm/dts/rockchip-u-boot.dtsi +20 -1
 			fit,external-offset = <CONFIG_FIT_EXTERNAL_OFFSET>;
 			fit,align = <512>;
-			offset = <CONFIG_SPL_PAD_TO>;
 			images {
 				u-boot {
 					description = "U-Boot";
@@ -164,6 +148,33 @@
 					fit,loadables;
 				};
 			};
+	};
+#endif /* HAS_FIT */
+
+	simple-bin {
+		filename = "u-boot-rockchip.bin";
+		pad-byte = <0xff>;
+
+		mkimage {
+			filename = "idbloader.img";
+			args = "-n", CONFIG_SYS_SOC, "-T", "rksd";
+			multiple-data-files;
+
+#ifdef CONFIG_ROCKCHIP_EXTERNAL_TPL
+			rockchip-tpl {
+			};
+#elif defined(CONFIG_TPL)
+			u-boot-tpl {
+			};
+#endif
+			u-boot-spl {

arch/arm/dts/rockchip-u-boot.dtsi line 180

Quoted 10 lines
arch/arm/dts/rockchip-u-boot.dtsi +7 -0
+			};
+		};
+
+#ifdef HAS_FIT
+		fit {
+			offset = <CONFIG_SPL_PAD_TO>;
+			insert-template = <&common_part>;
 		};
 #else
 		u-boot-img {

There is one more fit node in simple-bin-spi that should change to use #ifdef HAS_FIT. Also for consistency with fit/u-boot-img node in simple-bin-spi I recommend we move the #else/#endif to not include the offset and closing bracket.

I suggest something like the following fixup to be included in this patch:

arch/arm/dts/rockchip-u-boot.dtsi +3 -5
index c3013e75ed10..460bf15e0032 100644
@@ -41,7 +41,6 @@
 #endif
 			#address-cells = <1>;
 			fit,fdt-list = "of-list";
-			filename = "u-boot.itb";
 			fit,external-offset = <CONFIG_FIT_EXTERNAL_OFFSET>;
 			fit,align = <512>;
 			images {
@@ -173,14 +172,13 @@
 
 #ifdef HAS_FIT
 		fit {
-			offset = <CONFIG_SPL_PAD_TO>;
+			filename = "u-boot.itb";
 			insert-template = <&common_part>;
-		};
 #else
 		u-boot-img {
+#endif
 			offset = <CONFIG_SPL_PAD_TO>;
 		};
-#endif
 
 		fdtmap {
 		};
@@ -207,7 +205,7 @@
 			};
 		};
 
-#if defined(CONFIG_ARM64) || defined(CONFIG_SPL_OPTEE_IMAGE)
+#ifdef HAS_FIT
 		fit {
 			type = "blob";
 			filename = "u-boot.itb";

With something like that applied this is:

Regards,
Jonas

#24 lore raw

Re: [PATCH v2 12/35] rockchip: dts: Create a template for the FIT

Hi Jonas,

Quoted 159 lines · Jonas Karlman

Hi Simon,

Quoted 59 lines · Simon Glass

Move the FIT description into a template so that it can (later) be used in multiple places in the image.

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 57 ++++++++++++++++++-------------
 1 file changed, 34 insertions(+), 23 deletions(-)
arch/arm/dts/rockchip-u-boot.dtsi +7 -22
index 64a6b57d5fd..ca666ba0cd4 100644
@@ -19,6 +19,10 @@
 #define COMP "none"
 #endif
 
+#if defined(CONFIG_SPL_FIT) && (defined(CONFIG_ARM64) || defined(CONFIG_SPL_OPTEE_IMAGE))
+#define HAS_FIT
+#endif
+
 / {
      binman: binman {
              multiple-images;
@@ -27,28 +31,9 @@
 
 #ifdef CONFIG_SPL
 &binman {
-     simple-bin {
-             filename = "u-boot-rockchip.bin";
-             pad-byte = <0xff>;
-
-             mkimage {
-                     filename = "idbloader.img";
-                     args = "-n", CONFIG_SYS_SOC, "-T", "rksd";
-                     multiple-data-files;
-
-#ifdef CONFIG_ROCKCHIP_EXTERNAL_TPL
-                     rockchip-tpl {
-                     };
-#elif defined(CONFIG_TPL)
-                     u-boot-tpl {
-                     };
-#endif
-                     u-boot-spl {
-                     };
-             };
-
-#if defined(CONFIG_SPL_FIT) && (defined(CONFIG_ARM64) || defined(CONFIG_SPL_OPTEE_IMAGE))
-             fit: fit {
+#ifdef HAS_FIT
+     common_part: template-1 {
+                     type = "fit";
 #ifdef CONFIG_ARM64
                      description = "FIT image for U-Boot with bl31 (TF-A)";
 #else

arch/arm/dts/rockchip-u-boot.dtsi line 44

Quoted 1 line
arch/arm/dts/rockchip-u-boot.dtsi +0 -0
@@ -59,7 +44,6 @@
                      filename = "u-boot.itb";

Please move the filename prop to the fit node in this patch.

There are lots of guides and Linux image building scripts that depend on the u-boot.itb file, so we should continue to keep this file to be backward compatible for a few more releases.

Quoted 30 lines
arch/arm/dts/rockchip-u-boot.dtsi +20 -1
                      fit,external-offset = <CONFIG_FIT_EXTERNAL_OFFSET>;
                      fit,align = <512>;
-                     offset = <CONFIG_SPL_PAD_TO>;
                      images {
                              u-boot {
                                      description = "U-Boot";
@@ -164,6 +148,33 @@
                                      fit,loadables;
                              };
                      };
+     };
+#endif /* HAS_FIT */
+
+     simple-bin {
+             filename = "u-boot-rockchip.bin";
+             pad-byte = <0xff>;
+
+             mkimage {
+                     filename = "idbloader.img";
+                     args = "-n", CONFIG_SYS_SOC, "-T", "rksd";
+                     multiple-data-files;
+
+#ifdef CONFIG_ROCKCHIP_EXTERNAL_TPL
+                     rockchip-tpl {
+                     };
+#elif defined(CONFIG_TPL)
+                     u-boot-tpl {
+                     };
+#endif
+                     u-boot-spl {

arch/arm/dts/rockchip-u-boot.dtsi line 180

Quoted 10 lines
arch/arm/dts/rockchip-u-boot.dtsi +7 -0
+                     };
+             };
+
+#ifdef HAS_FIT
+             fit {
+                     offset = <CONFIG_SPL_PAD_TO>;
+                     insert-template = <&common_part>;
              };
 #else
              u-boot-img {

There is one more fit node in simple-bin-spi that should change to use #ifdef HAS_FIT. Also for consistency with fit/u-boot-img node in simple-bin-spi I recommend we move the #else/#endif to not include the offset and closing bracket.

I suggest something like the following fixup to be included in this patch:

arch/arm/dts/rockchip-u-boot.dtsi +3 -5
index c3013e75ed10..460bf15e0032 100644
@@ -41,7 +41,6 @@
 #endif
                        #address-cells = <1>;
                        fit,fdt-list = "of-list";
-                       filename = "u-boot.itb";
                        fit,external-offset = <CONFIG_FIT_EXTERNAL_OFFSET>;
                        fit,align = <512>;
                        images {
@@ -173,14 +172,13 @@
 
 #ifdef HAS_FIT
                fit {
-                       offset = <CONFIG_SPL_PAD_TO>;
+                       filename = "u-boot.itb";
                        insert-template = <&common_part>;
-               };
 #else
                u-boot-img {
+#endif
                        offset = <CONFIG_SPL_PAD_TO>;
                };
-#endif
 
                fdtmap {
                };
@@ -207,7 +205,7 @@
                        };
                };
 
-#if defined(CONFIG_ARM64) || defined(CONFIG_SPL_OPTEE_IMAGE)
+#ifdef HAS_FIT
                fit {
                        type = "blob";
                        filename = "u-boot.itb";
Quoted 1 line

With something like that applied this is:

Thanks for the patch, that helped me figure out what you wanted with the braces. I have tended to avoid #ifdef around open braces, but I agree it seems easier this way in this case.

Quoted 2 lines

Regards,
Simon

#25 lore raw

PATCH v2 13/35 rockchip: dts: Un-indent the FIT template

In reply to Simon Glass

Fix the indentation on the template. This is done in a separate patch so that it is easier to review.

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 178 +++++++++++++++---------------
 1 file changed, 89 insertions(+), 89 deletions(-)
arch/arm/dts/rockchip-u-boot.dtsi +89 -89
index ca666ba0cd4..281119a53d3 100644
@@ -33,121 +33,121 @@
 &binman {
 #ifdef HAS_FIT
 	common_part: template-1 {
-			type = "fit";
+		type = "fit";
 #ifdef CONFIG_ARM64
-			description = "FIT image for U-Boot with bl31 (TF-A)";
+		description = "FIT image for U-Boot with bl31 (TF-A)";
 #else
-			description = "FIT image with OP-TEE";
+		description = "FIT image with OP-TEE";
 #endif
-			#address-cells = <1>;
-			fit,fdt-list = "of-list";
-			filename = "u-boot.itb";
-			fit,external-offset = <CONFIG_FIT_EXTERNAL_OFFSET>;
-			fit,align = <512>;
-			images {
-				u-boot {
-					description = "U-Boot";
-					type = "standalone";
-					os = "u-boot";
-					arch = ARCH;
-					compression = COMP;
-					load = <CONFIG_TEXT_BASE>;
-					entry = <CONFIG_TEXT_BASE>;
-					u-boot-nodtb {
+		#address-cells = <1>;
+		fit,fdt-list = "of-list";
+		filename = "u-boot.itb";
+		fit,external-offset = <CONFIG_FIT_EXTERNAL_OFFSET>;
+		fit,align = <512>;
+		images {
+			u-boot {
+				description = "U-Boot";
+				type = "standalone";
+				os = "u-boot";
+				arch = ARCH;
+				compression = COMP;
+				load = <CONFIG_TEXT_BASE>;
+				entry = <CONFIG_TEXT_BASE>;
+				u-boot-nodtb {
 					compress = COMP;
-					};
+				};
 #ifdef CONFIG_SPL_FIT_SIGNATURE
-					hash {
-						algo = "sha256";
-					};
-#endif
+				hash {
+					algo = "sha256";
 				};
+#endif
+			};
 
 #ifdef CONFIG_ARM64
-				@atf-SEQ {
-					fit,operation = "split-elf";
-					description = "ARM Trusted Firmware";
-					type = "firmware";
-					arch = ARCH;
-					os = "arm-trusted-firmware";
-					compression = "none";
-					fit,load;
-					fit,entry;
-					fit,data;
-
-					atf-bl31 {
-					};
+			@atf-SEQ {
+				fit,operation = "split-elf";
+				description = "ARM Trusted Firmware";
+				type = "firmware";
+				arch = ARCH;
+				os = "arm-trusted-firmware";
+				compression = "none";
+				fit,load;
+				fit,entry;
+				fit,data;
+
+				atf-bl31 {
+				};
 #ifdef CONFIG_SPL_FIT_SIGNATURE
-					hash {
-						algo = "sha256";
-					};
+				hash {
+					algo = "sha256";
+				};
 #endif
+			};
+			@tee-SEQ {
+				fit,operation = "split-elf";
+				description = "TEE";
+				type = "tee";
+				arch = ARCH;
+				os = "tee";
+				compression = "none";
+				fit,load;
+				fit,entry;
+				fit,data;
+
+				tee-os {
+					optional;
 				};
-				@tee-SEQ {
-					fit,operation = "split-elf";
-					description = "TEE";
-					type = "tee";
-					arch = ARCH;
-					os = "tee";
-					compression = "none";
-					fit,load;
-					fit,entry;
-					fit,data;
-
-					tee-os {
-						optional;
-					};
 #ifdef CONFIG_SPL_FIT_SIGNATURE
-					hash {
-						algo = "sha256";
-					};
-#endif
+				hash {
+					algo = "sha256";
 				};
+#endif
+			};
 #else /* !CONFIG_ARM64 */
-				op-tee {
-					description = "OP-TEE";
-					type = "tee";
-					arch = ARCH;
-					os = "tee";
-					compression = "none";
-					load = <(CFG_SYS_SDRAM_BASE + 0x8400000)>;
-					entry = <(CFG_SYS_SDRAM_BASE + 0x8400000)>;
-
-					tee-os {
-					};
+			op-tee {
+				description = "OP-TEE";
+				type = "tee";
+				arch = ARCH;
+				os = "tee";
+				compression = "none";
+				load = <(CFG_SYS_SDRAM_BASE + 0x8400000)>;
+				entry = <(CFG_SYS_SDRAM_BASE + 0x8400000)>;
+
+				tee-os {
+				};
 #ifdef CONFIG_SPL_FIT_SIGNATURE
-					hash {
-						algo = "sha256";
-					};
-#endif
+				hash {
+					algo = "sha256";
 				};
+#endif
+			};
 #endif /* CONFIG_ARM64 */
 
-				@fdt-SEQ {
-					description = "fdt-NAME";
-					compression = "none";
-					type = "flat_dt";
+			@fdt-SEQ {
+				description = "fdt-NAME";
+				compression = "none";
+				type = "flat_dt";
 #ifdef CONFIG_SPL_FIT_SIGNATURE
-					hash {
-						algo = "sha256";
-					};
-#endif
+				hash {
+					algo = "sha256";
 				};
+#endif
 			};
+		};
 
-			configurations {
-				default = "@config-DEFAULT-SEQ";
-				@config-SEQ {
-					description = "NAME.dtb";
-					fdt = "fdt-SEQ";
+		configurations {
+			default = "@config-DEFAULT-SEQ";
+			@config-SEQ {
+				description = "NAME.dtb";
+				fdt = "fdt-SEQ";
 #ifdef CONFIG_ARM64
-					fit,firmware = "atf-1", "u-boot";
+				fit,firmware = "atf-1", "u-boot";
 #else
-					fit,firmware = "op-tee", "u-boot";
+				fit,firmware = "op-tee", "u-boot";
 #endif
-					fit,loadables;
-				};
+				fit,loadables;
 			};
+		};
 	};
 #endif /* HAS_FIT */
 
Signature · 1 line
2.43.0
Reviewed-by on v2 13/35
#26 lore raw

Re: [PATCH v2 13/35] rockchip: dts: Un-indent the FIT template

Quoted 4 lines · Simon Glass

Fix the indentation on the template. This is done in a separate patch so that it is easier to review.

Regards,
Jonas

Quoted 7 lines

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 178 +++++++++++++++---------------
 1 file changed, 89 insertions(+), 89 deletions(-)

[snip]

#27 lore raw

PATCH v2 14/35 rockchip: dts: Use the new binman template for the SPI image too

In reply to Simon Glass

At present simple-bin-spi relies on the u-boot.itb file created by the simple-bin image. Use the template to avoid this, since Binman may change to process images in parallel in the future.

Drop the filename to prevent another image being created which uses the u-boot.itb file.

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
arch/arm/dts/rockchip-u-boot.dtsi +1 -3
index 281119a53d3..79f4188b76b 100644
@@ -41,7 +41,6 @@
 #endif
 		#address-cells = <1>;
 		fit,fdt-list = "of-list";
-		filename = "u-boot.itb";
 		fit,external-offset = <CONFIG_FIT_EXTERNAL_OFFSET>;
 		fit,align = <512>;
 		images {
@@ -208,8 +207,7 @@
 
 #if defined(CONFIG_ARM64) || defined(CONFIG_SPL_OPTEE_IMAGE)
 		fit {
-			type = "blob";
-			filename = "u-boot.itb";
+			insert-template = <&common_part>;
 #else
 		u-boot-img {
 #endif
Signature · 1 line
2.43.0
Reviewed-by on v2 14/35
#28 lore raw

Re: [PATCH v2 14/35] rockchip: dts: Use the new binman template for the SPI image too

Hi Simon,

Quoted 6 lines · Simon Glass

At present simple-bin-spi relies on the u-boot.itb file created by the simple-bin image. Use the template to avoid this, since Binman may change to process images in parallel in the future.

Drop the filename to prevent another image being created which uses the u-boot.itb file.

As mentioned in "rockchip: dts: Create a template for the FIT", we should keep the u-boot.itb file a few more releases.

Quoted 23 lines

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
arch/arm/dts/rockchip-u-boot.dtsi +0 -1
index 281119a53d3..79f4188b76b 100644
@@ -41,7 +41,6 @@
 #endif
 		#address-cells = <1>;
 		fit,fdt-list = "of-list";
-		filename = "u-boot.itb";
 		fit,external-offset = <CONFIG_FIT_EXTERNAL_OFFSET>;
 		fit,align = <512>;
 		images {

arch/arm/dts/rockchip-u-boot.dtsi line 208

Quoted 2 lines
arch/arm/dts/rockchip-u-boot.dtsi +0 -0
@@ -208,8 +207,7 @@
 
 #if defined(CONFIG_ARM64) || defined(CONFIG_SPL_OPTEE_IMAGE)

As mentioned in "rockchip: dts: Create a template for the FIT", this should be changed to "#ifdef HAS_FIT".

arch/arm/dts/rockchip-u-boot.dtsi line 213

Quoted 7 lines
arch/arm/dts/rockchip-u-boot.dtsi +1 -2
 		fit {
-			type = "blob";
-			filename = "u-boot.itb";
+			insert-template = <&common_part>;
 #else
 		u-boot-img {
 #endif

Please also update u-boot.rom in rk3399-u-boot.dtsi to use this template.

With that included this is,

I also strongly recommend you break out following rockchip-u-boot.dtsi related patches into its own separate series:
- rockchip: dts: Correct the OS for U-Boot
- rockchip: dts: Factor out arch and compression
- rockchip: dts: Add an fdtmap
- rockchip: dts: Create a template for the FIT
- rockchip: dts: Un-indent the FIT template
- rockchip: dts: Use the new binman template for the SPI image too

Those patches stand on their own and help solve the "Entry 'u-boot-any' not found in list"-issue in "rockchip: Fix binman error" [1].

[1] https://patchwork.ozlabs.org/patch/2040246/

Regards,
Jonas

#29 lore raw

Re: [PATCH v2 14/35] rockchip: dts: Use the new binman template for the SPI image too

Hi Jonas,

Quoted 67 lines · Jonas Karlman

Hi Simon,

Quoted 6 lines · Simon Glass

At present simple-bin-spi relies on the u-boot.itb file created by the simple-bin image. Use the template to avoid this, since Binman may change to process images in parallel in the future.

Drop the filename to prevent another image being created which uses the u-boot.itb file.

As mentioned in "rockchip: dts: Create a template for the FIT", we should keep the u-boot.itb file a few more releases.

Quoted 23 lines

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
arch/arm/dts/rockchip-u-boot.dtsi +0 -1
index 281119a53d3..79f4188b76b 100644
@@ -41,7 +41,6 @@
 #endif
              #address-cells = <1>;
              fit,fdt-list = "of-list";
-             filename = "u-boot.itb";
              fit,external-offset = <CONFIG_FIT_EXTERNAL_OFFSET>;
              fit,align = <512>;
              images {

arch/arm/dts/rockchip-u-boot.dtsi line 208

Quoted 2 lines
arch/arm/dts/rockchip-u-boot.dtsi +0 -0
@@ -208,8 +207,7 @@
 
 #if defined(CONFIG_ARM64) || defined(CONFIG_SPL_OPTEE_IMAGE)

As mentioned in "rockchip: dts: Create a template for the FIT", this should be changed to "#ifdef HAS_FIT".

arch/arm/dts/rockchip-u-boot.dtsi line 213

Quoted 7 lines
arch/arm/dts/rockchip-u-boot.dtsi +1 -2
              fit {
-                     type = "blob";
-                     filename = "u-boot.itb";
+                     insert-template = <&common_part>;
 #else
              u-boot-img {
 #endif

Please also update u-boot.rom in rk3399-u-boot.dtsi to use this template.

With that included this is,

I also strongly recommend you break out following rockchip-u-boot.dtsi related patches into its own separate series:
- rockchip: dts: Correct the OS for U-Boot
- rockchip: dts: Factor out arch and compression
- rockchip: dts: Add an fdtmap
- rockchip: dts: Create a template for the FIT
- rockchip: dts: Un-indent the FIT template
- rockchip: dts: Use the new binman template for the SPI image too

Quoted 2 lines

Those patches stand on their own and help solve the "Entry 'u-boot-any' not found in list"-issue in "rockchip: Fix binman error" [1].

I'm pleased that this has some potential use outside of VBE. But this is the final VBE series and I really want VBE to work on a real board once this is applied. If you like, you could apply these patches separately, but your comments on the whole series have been very helpful.

Quoted 2 lines

[1] https://patchwork.ozlabs.org/patch/2040246/

Regards,
Simon

#30 lore raw

Re: [PATCH v2 14/35] rockchip: dts: Use the new binman template for the SPI image too

Hi Simon,

Quoted 70 lines · Simon Glass

Hi Jonas,

Quoted 67 lines · Jonas Karlman

Hi Simon,

Quoted 6 lines · Simon Glass

At present simple-bin-spi relies on the u-boot.itb file created by the simple-bin image. Use the template to avoid this, since Binman may change to process images in parallel in the future.

Drop the filename to prevent another image being created which uses the u-boot.itb file.

As mentioned in "rockchip: dts: Create a template for the FIT", we should keep the u-boot.itb file a few more releases.

Quoted 23 lines

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
arch/arm/dts/rockchip-u-boot.dtsi +0 -1
index 281119a53d3..79f4188b76b 100644
@@ -41,7 +41,6 @@
 #endif
              #address-cells = <1>;
              fit,fdt-list = "of-list";
-             filename = "u-boot.itb";
              fit,external-offset = <CONFIG_FIT_EXTERNAL_OFFSET>;
              fit,align = <512>;
              images {

arch/arm/dts/rockchip-u-boot.dtsi line 208

Quoted 2 lines
arch/arm/dts/rockchip-u-boot.dtsi +0 -0
@@ -208,8 +207,7 @@
 
 #if defined(CONFIG_ARM64) || defined(CONFIG_SPL_OPTEE_IMAGE)

As mentioned in "rockchip: dts: Create a template for the FIT", this should be changed to "#ifdef HAS_FIT".

arch/arm/dts/rockchip-u-boot.dtsi line 213

Quoted 7 lines
arch/arm/dts/rockchip-u-boot.dtsi +1 -2
              fit {
-                     type = "blob";
-                     filename = "u-boot.itb";
+                     insert-template = <&common_part>;
 #else
              u-boot-img {
 #endif

Please also update u-boot.rom in rk3399-u-boot.dtsi to use this template.

With that included this is,

I also strongly recommend you break out following rockchip-u-boot.dtsi related patches into its own separate series:
- rockchip: dts: Correct the OS for U-Boot
- rockchip: dts: Factor out arch and compression
- rockchip: dts: Add an fdtmap
- rockchip: dts: Create a template for the FIT
- rockchip: dts: Un-indent the FIT template
- rockchip: dts: Use the new binman template for the SPI image too

Quoted 8 lines
Quoted 2 lines

Those patches stand on their own and help solve the "Entry 'u-boot-any' not found in list"-issue in "rockchip: Fix binman error" [1].

I'm pleased that this has some potential use outside of VBE. But this is the final VBE series and I really want VBE to work on a real board once this is applied. If you like, you could apply these patches separately, but your comments on the whole series have been very helpful.

Yes, I would prefer to see these rockchip: dts: patches applied separately before remaining patches in this VBE series, mostly because these are fixing issues affecting others such as [1][2] and I also have a pending maskrom RAM-boot series that will depend on the common_part template added here or use a similar approach as in [2].

However, the remaining VBE patches in this series has not yet been fully reviewed or tested and may need further work and/or rebasing before being fully ready. So to not block others I think the best approach will be to split this VBE series into smaller parts.

[2] https://patchwork.ozlabs.org/patch/2045541/

Regards,
Jonas

Quoted 6 lines
Quoted 3 lines

[1] https://patchwork.ozlabs.org/patch/2040246/

Regards,
Simon

#31 lore raw

PATCH v2 15/35 rockchip: dts: Specify the phase in the image

In reply to Simon Glass

Add 'u-boot' as the phase for the images intended for use with U-Boot proper.

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 4 ++++
 1 file changed, 4 insertions(+)
arch/arm/dts/rockchip-u-boot.dtsi +4 -0
index 79f4188b76b..c899e8e6005 100644
@@ -52,6 +52,7 @@
 				compression = COMP;
 				load = <CONFIG_TEXT_BASE>;
 				entry = <CONFIG_TEXT_BASE>;
+				phase = "u-boot";
 				u-boot-nodtb {
 					compress = COMP;
 				};
@@ -70,6 +71,7 @@
 				arch = ARCH;
 				os = "arm-trusted-firmware";
 				compression = "none";
+				phase = "u-boot";
 				fit,load;
 				fit,entry;
 				fit,data;
@@ -89,6 +91,7 @@
 				arch = ARCH;
 				os = "tee";
 				compression = "none";
+				phase = "u-boot";
 				fit,load;
 				fit,entry;
 				fit,data;
@@ -111,6 +114,7 @@
 				compression = "none";
 				load = <(CFG_SYS_SDRAM_BASE + 0x8400000)>;
 				entry = <(CFG_SYS_SDRAM_BASE + 0x8400000)>;
+				phase = "u-boot";
 
 				tee-os {
 				};
Signature · 1 line
2.43.0
#32 lore raw

PATCH v2 16/35 rockchip: Provide a bootstd configuration

In reply to Simon Glass

Add bootstd information for VBE. Put it in a separate file to avoid cluttering the main one.

---

Changes in v2:
- Move VPL things into a separate file

 arch/arm/dts/rockchip-u-boot.dtsi     |  4 ++++
 arch/arm/dts/rockchip-vpl-u-boot.dtsi | 31 +++++++++++++++++++++++++++
 2 files changed, 35 insertions(+)
 create mode 100644 arch/arm/dts/rockchip-vpl-u-boot.dtsi
arch/arm/dts/rockchip-u-boot.dtsi +4 -0
index c899e8e6005..10563e273a9 100644
@@ -224,3 +224,7 @@
 #endif /* CONFIG_ROCKCHIP_SPI_IMAGE */
 };
 #endif /* CONFIG_SPL */
+
+#ifdef CONFIG_VPL
+#include "rockchip-vpl-u-boot.dtsi"
+#endif
arch/arm/dts/rockchip-vpl-u-boot.dtsi new file +31 -0
new file mode 100644
index 00000000000..26b77e67c80
@@ -0,0 +1,31 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2019 Jagan Teki <[email protected]>
+ */
+
+/ {
+	bootstd {
+		bootph-verify;
+		compatible = "u-boot,boot-std";
+
+		/*
+		 * This is used for the VBE OS-request tests. A FAT filesystem
+		 * created in a partition with the VBE information appearing
+		 * before the partition starts.
+		 *
+		 * Offsets are aligned to the media block-size, typically 0x200
+		 */
+		firmware0 {
+			bootph-verify;
+			compatible = "fwupd,vbe-abrec";
+			storage = "mmc0";
+			skip-offset = <0x8000>;
+			area-start = <CONFIG_SPL_PAD_TO>;
+			area-size = <0x800000>;
+			state-offset = <(CONFIG_SPL_PAD_TO - 0x400)>;
+			state-size = <0x40>;
+			version-offset = <(CONFIG_SPL_PAD_TO - 0x200)>;
+			version-size = <0x100>;
+		};
+	};
+};
Signature · 1 line
2.43.0
#33 lore raw

Re: [PATCH v2 16/35] rockchip: Provide a bootstd configuration

Hi Simon,

Quoted 43 lines · Simon Glass

Add bootstd information for VBE. Put it in a separate file to avoid cluttering the main one.

---

Changes in v2:
- Move VPL things into a separate file

 arch/arm/dts/rockchip-u-boot.dtsi     |  4 ++++
 arch/arm/dts/rockchip-vpl-u-boot.dtsi | 31 +++++++++++++++++++++++++++
 2 files changed, 35 insertions(+)
 create mode 100644 arch/arm/dts/rockchip-vpl-u-boot.dtsi
arch/arm/dts/rockchip-u-boot.dtsi +4 -0
index c899e8e6005..10563e273a9 100644
@@ -224,3 +224,7 @@
 #endif /* CONFIG_ROCKCHIP_SPI_IMAGE */
 };
 #endif /* CONFIG_SPL */
+
+#ifdef CONFIG_VPL
+#include "rockchip-vpl-u-boot.dtsi"
+#endif
arch/arm/dts/rockchip-vpl-u-boot.dtsi new file +11 -0
new file mode 100644
index 00000000000..26b77e67c80
@@ -0,0 +1,31 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2019 Jagan Teki <[email protected]>
+ */
+
+/ {
+	bootstd {
+		bootph-verify;
+		compatible = "u-boot,boot-std";
+
+		/*

arch/arm/dts/rockchip-vpl-u-boot.dtsi line 21

Quoted 10 lines
arch/arm/dts/rockchip-vpl-u-boot.dtsi new file +10 -0
+		 * This is used for the VBE OS-request tests. A FAT filesystem
+		 * created in a partition with the VBE information appearing
+		 * before the partition starts.
+		 *
+		 * Offsets are aligned to the media block-size, typically 0x200
+		 */
+		firmware0 {
+			bootph-verify;
+			compatible = "fwupd,vbe-abrec";
+			storage = "mmc0";

This is probably board specific and can mean either emmc or sd-card in Linux depending on the DT for the board. U-Boot will for most Rockchip SoCs always treat mmc0 as emmc and mmc1 as sd-card thanks to override in <soc>-u-boot.dtsi and/or driver code.

arch/arm/dts/rockchip-vpl-u-boot.dtsi line 23

Quoted 2 lines
arch/arm/dts/rockchip-vpl-u-boot.dtsi new file +2 -0
+			skip-offset = <0x8000>;
+			area-start = <CONFIG_SPL_PAD_TO>;

SPL_PAD_TO is defined as "Image offset to which the SPL should be padded before appending the SPL payload." so should probably not be used to declare offset in storage.

arch/arm/dts/rockchip-vpl-u-boot.dtsi line 28

Quoted 5 lines
arch/arm/dts/rockchip-vpl-u-boot.dtsi new file +5 -0
+			area-size = <0x800000>;
+			state-offset = <(CONFIG_SPL_PAD_TO - 0x400)>;
+			state-size = <0x40>;
+			version-offset = <(CONFIG_SPL_PAD_TO - 0x200)>;
+			version-size = <0x100>;

All these offsets and sizes seem a bit arbitrary without any context. Please add more details about the layout used in a comment and/or commit message.

Regards,
Jonas

Quoted 3 lines
arch/arm/dts/rockchip-vpl-u-boot.dtsi new file +3 -0
+		};
+	};
+};
#34 lore raw

Re: [PATCH v2 16/35] rockchip: Provide a bootstd configuration

Hi Jonas,

Quoted 54 lines · Jonas Karlman

Hi Simon,

Quoted 50 lines · Simon Glass

Add bootstd information for VBE. Put it in a separate file to avoid cluttering the main one.

---

Changes in v2:
- Move VPL things into a separate file

 arch/arm/dts/rockchip-u-boot.dtsi     |  4 ++++
 arch/arm/dts/rockchip-vpl-u-boot.dtsi | 31 +++++++++++++++++++++++++++
 2 files changed, 35 insertions(+)
 create mode 100644 arch/arm/dts/rockchip-vpl-u-boot.dtsi
arch/arm/dts/rockchip-u-boot.dtsi +4 -0
index c899e8e6005..10563e273a9 100644
@@ -224,3 +224,7 @@
 #endif /* CONFIG_ROCKCHIP_SPI_IMAGE */
 };
 #endif /* CONFIG_SPL */
+
+#ifdef CONFIG_VPL
+#include "rockchip-vpl-u-boot.dtsi"
+#endif
arch/arm/dts/rockchip-vpl-u-boot.dtsi new file +18 -0
new file mode 100644
index 00000000000..26b77e67c80
@@ -0,0 +1,31 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2019 Jagan Teki <[email protected]>
+ */
+
+/ {
+     bootstd {
+             bootph-verify;
+             compatible = "u-boot,boot-std";
+
+             /*
+              * This is used for the VBE OS-request tests. A FAT filesystem
+              * created in a partition with the VBE information appearing
+              * before the partition starts.
+              *
+              * Offsets are aligned to the media block-size, typically 0x200
+              */
+             firmware0 {
Quoted 8 lines

arch/arm/dts/rockchip-vpl-u-boot.dtsi line 21

Quoted 3 lines
arch/arm/dts/rockchip-vpl-u-boot.dtsi new file +3 -0
+                     bootph-verify;
+                     compatible = "fwupd,vbe-abrec";
+                     storage = "mmc0";

This is probably board specific and can mean either emmc or sd-card in Linux depending on the DT for the board. U-Boot will for most Rockchip SoCs always treat mmc0 as emmc and mmc1 as sd-card thanks to override in <soc>-u-boot.dtsi and/or driver code.

OK.

Quoted 7 lines

arch/arm/dts/rockchip-vpl-u-boot.dtsi line 23

Quoted 3 lines
arch/arm/dts/rockchip-vpl-u-boot.dtsi new file +2 -0
+                     skip-offset = <0x8000>;
+                     area-start = <CONFIG_SPL_PAD_TO>;

SPL_PAD_TO is defined as "Image offset to which the SPL should be padded before appending the SPL payload." so should probably not be used to declare offset in storage.

OK, I'll use a separate value.

Quoted 10 lines

arch/arm/dts/rockchip-vpl-u-boot.dtsi line 28

Quoted 6 lines
arch/arm/dts/rockchip-vpl-u-boot.dtsi new file +5 -0
+                     area-size = <0x800000>;
+                     state-offset = <(CONFIG_SPL_PAD_TO - 0x400)>;
+                     state-size = <0x40>;
+                     version-offset = <(CONFIG_SPL_PAD_TO - 0x200)>;
+                     version-size = <0x100>;

All these offsets and sizes seem a bit arbitrary without any context. Please add more details about the layout used in a comment and/or commit message.

Will do.

Regards,
SImon

#35 lore raw

PATCH v2 17/35 rockchip: Add SPL into the main FIT

In reply to Simon Glass

VBE may want to load the SPL image from the same FIT as contains U-Boot, if there is enough memory, so add it.

Changes in v2:
- Move VPL things into a separate file

---

(no changes since v1)

 arch/arm/dts/rockchip-vpl-u-boot.dtsi | 29 +++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)
arch/arm/dts/rockchip-vpl-u-boot.dtsi +29 -0
index 26b77e67c80..325c15f9fef 100644
@@ -29,3 +29,32 @@
 		};
 	};
 };
+
+&binman {
+	template-1 {
+		images {
+			spl {
+				description = "U-Boot SPL";
+				type = "firmware";
+				os = "u-boot";
+				arch = ARCH;
+				compression = "lz4";
+				load = <CONFIG_SPL_TEXT_BASE>;
+				entry = <CONFIG_SPL_TEXT_BASE>;
+				phase = "spl";
+				section {
+					compress = "lz4";
+					u-boot-spl-nodtb {
+					};
+					u-boot-spl-bss-pad {
+					};
+				};
+			};
+		};
+		configurations {
+			@config-SEQ {
+				fit,firmware = "atf-1", "u-boot", "spl";
+			};
+		};
+	};
+};
Signature · 1 line
2.43.0
#36 lore raw

PATCH v2 18/35 rockchip: Include a compatible string in each configuration

In reply to Simon Glass

Provide a compatible string so that U-Boot can decide which configuration to use.

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 1 +
 1 file changed, 1 insertion(+)
arch/arm/dts/rockchip-u-boot.dtsi +1 -0
index 10563e273a9..c2a795957fb 100644
@@ -149,6 +149,7 @@
 				fit,firmware = "op-tee", "u-boot";
 #endif
 				fit,loadables;
+				fit,compatible;
 			};
 		};
 	};
Signature · 1 line
2.43.0
Reviewed-by on v2 18/35
#37 lore raw

Re: [PATCH v2 18/35] rockchip: Include a compatible string in each configuration

Hi Simon,

Quoted 4 lines · Simon Glass

Provide a compatible string so that U-Boot can decide which configuration to use.

This will be useful for more than VBE so this is:

Regards,
Jonas

Quoted 19 lines

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 1 +
 1 file changed, 1 insertion(+)
arch/arm/dts/rockchip-u-boot.dtsi +1 -0
index 10563e273a9..c2a795957fb 100644
@@ -149,6 +149,7 @@
 				fit,firmware = "op-tee", "u-boot";
 #endif
 				fit,loadables;
+				fit,compatible;
 			};
 		};
 	};
#38 lore raw

PATCH v2 19/35 rockchip: Add a template for SPL

In reply to Simon Glass

The SPL phase has a single SPL binary plus a devicetree for each board we need to support.

The devicetree is run through fdtgrep to remove unwanted nodes and properties and reduce its size.

While it would be nicer to just have a single FIT holding both the SPL and U-Boot images, there may not be enough SRAM to support that. So we end up providing this special image just for SPL.

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 43 +++++++++++++++++++++++++++++++
 1 file changed, 43 insertions(+)
arch/arm/dts/rockchip-u-boot.dtsi +43 -0
index c2a795957fb..9525cb9c21a 100644
@@ -153,6 +153,49 @@
 			};
 		};
 	};
+
+	spl_template: template-2 {
+		type = "fit";
+		description = "FIT image for U-Boot SPL";
+		#address-cells = <1>;
+		fit,fdt-list = "of-list";
+		fit,align = <512>;
+		fit,external-offset = <0>;
+		images {
+			spl {
+				description = "U-Boot SPL";
+				type = "firmware";
+				os = "u-boot";
+				arch = ARCH;
+				compression = "lz4";
+				load = <CONFIG_SPL_TEXT_BASE>;
+				entry = <CONFIG_SPL_TEXT_BASE>;
+				section {
+					compress = "lz4";
+					u-boot-spl-nodtb {
+					};
+					u-boot-spl-bss-pad {
+					};
+				};
+			};
+			@fdt-SEQ {
+				description = "fdt-NAME";
+				compression = "none";
+				type = "flat_dt";
+				fit,fdt-phase = "spl";
+			};
+		};
+		configurations {
+			default = "@config-DEFAULT-SEQ";
+			@config-SEQ {
+				description = "NAME.dtb";
+				fdt = "fdt-SEQ";
+				fit,firmware = "spl";
+				fit,loadables;
+				fit,compatible;
+			};
+		};
+	};
 #endif /* HAS_FIT */
 
 	simple-bin {
Signature · 1 line
2.43.0
#39 lore raw

Re: [PATCH v2 19/35] rockchip: Add a template for SPL

Hi Simon,

Quoted 59 lines · Simon Glass

The SPL phase has a single SPL binary plus a devicetree for each board we need to support.

The devicetree is run through fdtgrep to remove unwanted nodes and properties and reduce its size.

While it would be nicer to just have a single FIT holding both the SPL and U-Boot images, there may not be enough SRAM to support that. So we end up providing this special image just for SPL.

---

(no changes since v1)

 arch/arm/dts/rockchip-u-boot.dtsi | 43 +++++++++++++++++++++++++++++++
 1 file changed, 43 insertions(+)
arch/arm/dts/rockchip-u-boot.dtsi +33 -0
index c2a795957fb..9525cb9c21a 100644
@@ -153,6 +153,49 @@
 			};
 		};
 	};
+
+	spl_template: template-2 {
+		type = "fit";
+		description = "FIT image for U-Boot SPL";
+		#address-cells = <1>;
+		fit,fdt-list = "of-list";
+		fit,align = <512>;
+		fit,external-offset = <0>;
+		images {
+			spl {
+				description = "U-Boot SPL";
+				type = "firmware";
+				os = "u-boot";
+				arch = ARCH;
+				compression = "lz4";
+				load = <CONFIG_SPL_TEXT_BASE>;
+				entry = <CONFIG_SPL_TEXT_BASE>;
+				section {
+					compress = "lz4";
+					u-boot-spl-nodtb {
+					};
+					u-boot-spl-bss-pad {
+					};
+				};
+			};
+			@fdt-SEQ {
+				description = "fdt-NAME";
+				compression = "none";
+				type = "flat_dt";
+				fit,fdt-phase = "spl";
+			};
+		};
+		configurations {

arch/arm/dts/rockchip-u-boot.dtsi line 198

Quoted 10 lines
arch/arm/dts/rockchip-u-boot.dtsi +10 -0
+			default = "@config-DEFAULT-SEQ";
+			@config-SEQ {
+				description = "NAME.dtb";
+				fdt = "fdt-SEQ";
+				fit,firmware = "spl";
+				fit,loadables;
+				fit,compatible;
+			};
+		};
+	};

This template look very specific to VBE/VPL and can probably also be moved to rockchip-vpl-u-boot.dtsi. Else this could need a comment on e.g. why this does not use COMP as compression algo.

Regards,
Jonas

Quoted 3 lines
arch/arm/dts/rockchip-u-boot.dtsi +0 -0
 #endif /* HAS_FIT */
 
 	simple-bin {
#40 lore raw

PATCH v2 20/35 rockchip: Add a VPL image

In reply to Simon Glass

The VPL image is immutable and has a single VPL binary plus a devicetree for each board we need to support.

The devicetree is run through fdtgrep to remove unwanted nodes and properties and reduce its size.

Changes in v2:
- Move VPL things into a separate file

---

(no changes since v1)

 arch/arm/dts/rockchip-vpl-u-boot.dtsi | 91 +++++++++++++++++++++++++++
 1 file changed, 91 insertions(+)
arch/arm/dts/rockchip-vpl-u-boot.dtsi +91 -0
index 325c15f9fef..a02f44d27d2 100644
@@ -57,4 +57,95 @@
 			};
 		};
 	};
+
+	simple-bin {
+		vpl {
+			type = "fit";
+			offset = <(CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 0x200 + 0x8000)>;
+			description = "FIT image for U-Boot TPL";
+			#address-cells = <1>;
+			fit,fdt-list = "of-list";
+			fit,align = <512>;
+			fit,external-offset = <0>;
+			images {
+				image-vpl {
+					description = "U-Boot VPL";
+					type = "firmware";
+					os = "u-boot";
+					arch = ARCH;
+					compression = "lz4";
+					load = <CONFIG_VPL_TEXT_BASE>;
+					entry = <CONFIG_VPL_TEXT_BASE>;
+					section {
+						compress = "lz4";
+						u-boot-vpl-nodtb {
+							symbols-base = <0>;
+						};
+						u-boot-vpl-bss-pad {
+						};
+					};
+				};
+				@fdt-SEQ {
+					description = "fdt-NAME";
+					compression = "none";
+					type = "flat_dt";
+					fit,fdt-phase = "vpl";
+				};
+			};
+			configurations {
+				default = "@config-DEFAULT-SEQ";
+				@config-SEQ {
+					description = "NAME.dtb";
+					fdt = "fdt-SEQ";
+					fit,firmware = "image-vpl";
+					fit,loadables;
+					fit,compatible;
+				};
+			};
+		};
+# ifdef CONFIG_BOOTMETH_VBE_ABREC
+		vbe-a {
+			type = "section";
+			offset = <(CONFIG_SPL_PAD_TO + 0x8000)>;
+			spl-a {
+				insert-template = <&spl_template>;
+				size = <0x100000>;
+			};
+
+			u-boot-a {
+				insert-template = <&common_part>;
+			};
+		};
+		vbe-b {
+			type = "section";
+			offset = <0x1000000>;
+			spl-b {
+				insert-template = <&spl_template>;
+				size = <0x100000>;
+			};
+
+			u-boot-b {
+				insert-template = <&common_part>;
+			};
+		};
+		vbe-recovery {
+			type = "section";
+			offset = <0x1800000>;
+			spl-recovery {
+				insert-template = <&spl_template>;
+				size = <0x100000>;
+			};
+
+			u-boot-recovery {
+				insert-template = <&common_part>;
+			};
+		};
+# else /* CONFIG_BOOTMETH_VBE_SIMPLE */
+		vbe {
+			type = "fit";
+			offset = <(CONFIG_SPL_PAD_TO + 0x8000)>;
+			insert-template = <&common_part>;
+		};
+# endif /* VBE method */
+	};
 };
Signature · 1 line
2.43.0
#41 lore raw

PATCH v2 21/35 rockchip: Add TPL alternatives

In reply to Simon Glass

The TPL image must be built for each board we need to support. It is the only part of the image which is board-specific.

This helps to save space and reduce the size of TPL, so that it can fit within the internal 192K IRAM of the RK3399 SoC.

As with other phases, the TPL devicetree is run through fdtgrep to remove unwanted nodes and properties and reduce its size.

---

Changes in v2:
- Mention RK3399 with respect to the memory limit
- Move VPL things into a separate file

 arch/arm/dts/rockchip-u-boot.dtsi     |  4 +++-
 arch/arm/dts/rockchip-vpl-u-boot.dtsi | 16 ++++++++++++++++
 2 files changed, 19 insertions(+), 1 deletion(-)
arch/arm/dts/rockchip-u-boot.dtsi +3 -1
index 9525cb9c21a..0d59aad86bf 100644
@@ -202,6 +202,7 @@
 		filename = "u-boot-rockchip.bin";
 		pad-byte = <0xff>;
 
+#ifndef CONFIG_VPL
 		mkimage {
 			filename = "idbloader.img";
 			args = "-n", CONFIG_SYS_SOC, "-T", "rksd";
@@ -227,7 +228,8 @@
 		u-boot-img {
 			offset = <CONFIG_SPL_PAD_TO>;
 		};
-#endif
+#endif /* HAS_FIT */
+#endif /* VPL */
 		fdtmap {
 		};
 	};
arch/arm/dts/rockchip-vpl-u-boot.dtsi +16 -0
index a02f44d27d2..621161f6c86 100644
@@ -59,6 +59,22 @@
 	};
 
 	simple-bin {
+		alternates-fdt {
+			fdt-list-dir = "dts/upstream/src/arm64/rockchip";
+			filename-pattern = "alt-NAME.bin";
+			fdt-phase = "tpl";
+
+			mkimage {
+				filename = "idbloader.img";
+				args = "-n", CONFIG_SYS_SOC, "-T", "rksd";
+				multiple-data-files;
+
+				u-boot-tpl {
+					symbols-base = <0>;
+				};
+			};
+		};
+
 		vpl {
 			type = "fit";
 			offset = <(CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 0x200 + 0x8000)>;
Signature · 1 line
2.43.0
#42 lore raw

PATCH v2 22/35 rockchip: Update rk3399 bootph-tags for VPL

In reply to Simon Glass

When VPL is in use, memory init happens in SPL, so there is no need to include the DMC device before that. Adjust the tags to save space.

---

Changes in v2:
- Only enable MMC when VPM is in use.

 arch/arm/dts/rk3399-u-boot.dtsi | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)
arch/arm/dts/rk3399-u-boot.dtsi +10 -1
index 81a3c6fc972..c3d0da62c8f 100644
@@ -71,7 +71,12 @@
 	       0x0 0xffa88800 0x0 0x1800
 	       0x0 0xffa8a000 0x0 0x2000
 	       0x0 0xffa8c000 0x0 0x1000>;
-	bootph-all;
+#ifdef CONFIG_VPL
+		bootph-pre-ram;
+		bootph-some-ram;
+#else
+		bootph-all;
+#endif
 	status = "okay";
 };
 
@@ -118,6 +123,10 @@
 };
 
 &sdmmc {
+#ifdef CONFIG_VPL
+	bootph-pre-sram;
+	bootph-verify;
+#endif
 	bootph-pre-ram;
 	bootph-some-ram;
 
Signature · 1 line
2.43.0
#43 lore raw

PATCH v2 23/35 rockchip: Provide a VPL phase on rk3399

In reply to Simon Glass

Add support for this new phase, which runs after TPL. It determines the state of the machine, then selects which SPL image to use. SDRAM init is then done in SPL, so that it is updatable.

---

Changes in v2:
- Rewrite help for VPL_ROCKCHIP_COMMON_BOARD
- Skip spl-boot-order.c for VPL (rather than modifying it)

 arch/arm/include/asm/spl.h               |   1 +
 arch/arm/mach-rockchip/Kconfig           |  25 +++++-
 arch/arm/mach-rockchip/Makefile          |  11 ++-
 arch/arm/mach-rockchip/rk3399/Kconfig    |   9 ++
 arch/arm/mach-rockchip/spl.c             |   3 +
 arch/arm/mach-rockchip/tpl.c             |   2 +-
 arch/arm/mach-rockchip/u-boot-vpl-v8.lds | 107 +++++++++++++++++++++++
 arch/arm/mach-rockchip/vpl.c             |  53 +++++++++++
 common/spl/Kconfig                       |   1 +
 9 files changed, 205 insertions(+), 7 deletions(-)
 create mode 100644 arch/arm/mach-rockchip/u-boot-vpl-v8.lds
 create mode 100644 arch/arm/mach-rockchip/vpl.c
arch/arm/include/asm/spl.h +1 -0
index ee79a19c05c..62844d64cab 100644
@@ -30,6 +30,7 @@ enum {
 	BOOT_DEVICE_XIP,
 	BOOT_DEVICE_BOOTROM,
 	BOOT_DEVICE_SMH,
+	BOOT_DEVICE_VBE,
 	BOOT_DEVICE_NONE
 };
 #endif
arch/arm/mach-rockchip/Kconfig +21 -4
index 4c515593718..58ba0e0468f 100644
@@ -252,13 +252,15 @@ config ROCKCHIP_RK3399
 	select SPL_ATF
 	select SPL_BOARD_INIT if SPL
 	select SPL_LOAD_FIT
-	select SPL_CLK if SPL
+	select SPL_CLK if SPL && !VPL
 	select SPL_PINCTRL if SPL
 	select SPL_RAM if SPL
 	select SPL_REGMAP if SPL
 	select SPL_SYSCON if SPL
 	select TPL_HAVE_INIT_STACK if TPL
-	select SPL_SEPARATE_BSS
+	select VPL_HAVE_INIT_STACK if VPL
+	select SPL_SEPARATE_BSS if !VPL
+	select SPL_RAW_IMAGE_SUPPORT if VPL
 	select CLK
 	select FIT
 	select PINCTRL
@@ -268,6 +270,7 @@ config ROCKCHIP_RK3399
 	select DM_PMIC
 	select DM_REGULATOR_FIXED
 	select BOARD_LATE_INIT
+	select SUPPORT_VPL
 	imply ARMV8_CRYPTO
 	imply ARMV8_SET_SMPEN
 	imply BOOTSTD_FULL
@@ -296,13 +299,14 @@ config ROCKCHIP_RK3399
 	imply TPL_LIBCOMMON_SUPPORT
 	imply TPL_LIBGENERIC_SUPPORT
 	imply TPL_OF_CONTROL
-	imply TPL_RAM
+	imply TPL_RAM if !VPL
 	imply TPL_REGMAP
 	imply TPL_ROCKCHIP_COMMON_BOARD
 	imply TPL_SERIAL
 	imply TPL_SYS_MALLOC_SIMPLE
 	imply TPL_SYSCON
 	imply TPL_TINY_MEMSET
+	imply TPL_DM_MMC if VPL
 	help
 	  The Rockchip RK3399 is a ARM-based SoC with a dual-core Cortex-A72
 	  and quad-core Cortex-A53.
@@ -457,7 +461,7 @@ config SPL_ROCKCHIP_BACK_TO_BROM
 
 config TPL_ROCKCHIP_BACK_TO_BROM
 	bool "TPL returns to bootrom"
-	default y
+	default y if !VPL
 	select ROCKCHIP_BROM_HELPER if !ROCKCHIP_RK3066
 	select TPL_BOOTROM_SUPPORT
 	depends on TPL
@@ -498,6 +502,16 @@ config ROCKCHIP_EXTERNAL_TPL
 	  Enable this option and build with ROCKCHIP_TPL=/path/to/ddr.bin to
 	  include the external TPL in the image built by binman.
 
+config VPL_ROCKCHIP_COMMON_BOARD
+	bool "Rockchip VPL common board file"
+	depends on VPL
+	default y
+	help
+	  Enable the VPL phase for rockchip, which selects which SPL/U-Boot
+	  will be used on each boot. With this flow, used by Verified Boot for
+	  Embedded (VBE), TPL is loaded by the boot ROM. Then TPL loads VPL,
+	  VPL loads SPL and SPL loads U-Boot.
+
 config ROCKCHIP_BOOT_MODE_REG
 	hex "Rockchip boot mode flag register address"
 	help
@@ -589,6 +603,9 @@ config TPL_ROCKCHIP_EARLYRETURN_TO_BROM
 config SPL_MMC
 	default y if !SPL_ROCKCHIP_BACK_TO_BROM
 
+config TPL_MMC
+	default y if !TPL_ROCKCHIP_BACK_TO_BROM
+
 config ROCKCHIP_SPI_IMAGE
 	bool "Build a SPI image for rockchip"
 	help
arch/arm/mach-rockchip/Makefile +9 -2
index 5e7edc99cdc..c39de1f78bb 100644
@@ -8,11 +8,16 @@
 # inaccessible/protected memory (and the bootrom-helper assumes that
 # the stack-pointer is valid before switching to the U-Boot stack).
 obj-spl-$(CONFIG_ROCKCHIP_BROM_HELPER) += bootrom.o
-obj-spl-$(CONFIG_SPL_ROCKCHIP_COMMON_BOARD) += spl.o spl-boot-order.o spl_common.o
+obj-spl-$(CONFIG_SPL_ROCKCHIP_COMMON_BOARD) += spl.o spl_common.o
+ifndef CONFIG_VPL
+obj-spl-$(CONFIG_SPL_ROCKCHIP_COMMON_BOARD) += spl-boot-order.o
+endif
 obj-tpl-$(CONFIG_ROCKCHIP_BROM_HELPER) += bootrom.o
 obj-tpl-$(CONFIG_TPL_ROCKCHIP_COMMON_BOARD) += tpl.o spl_common.o
 obj-tpl-$(CONFIG_ROCKCHIP_PX30) += px30-board-tpl.o
 
+obj-vpl-$(CONFIG_VPL_ROCKCHIP_COMMON_BOARD) += vpl.o
+
 obj-spl-$(CONFIG_ROCKCHIP_RK3036) += rk3036-board-spl.o
 
 ifeq ($(CONFIG_XPL_BUILD)$(CONFIG_TPL_BUILD),)
@@ -47,9 +52,11 @@ obj-$(CONFIG_ROCKCHIP_RK3588) += rk3588/
 obj-$(CONFIG_ROCKCHIP_RV1108) += rv1108/
 obj-$(CONFIG_ROCKCHIP_RV1126) += rv1126/
 
-# Clear out SPL objects, in case this is a TPL build
+# Clear out SPL objects, in case this is a TPL or VPL build
 obj-spl-$(CONFIG_TPL_BUILD) =
+obj-spl-$(CONFIG_VPL_BUILD) =
 
 # Now add SPL/TPL objects back into the main build
 obj-$(CONFIG_XPL_BUILD) += $(obj-spl-y)
 obj-$(CONFIG_TPL_BUILD) += $(obj-tpl-y)
+obj-$(CONFIG_VPL_BUILD) += $(obj-vpl-y)
arch/arm/mach-rockchip/rk3399/Kconfig +9 -0
index 04a84e2f6a0..fc55b498111 100644
@@ -164,6 +164,15 @@ config TPL_STACK
 config TPL_TEXT_BASE
         default 0xff8c2000
 
+config VPL_STACK
+        default 0xff8eff00
+
+config VPL_TEXT_BASE
+        default 0xff8c2000
+
+config VPL_LDSCRIPT
+	default "arch/arm/mach-rockchip/u-boot-vpl-v8.lds"
+
 config SPL_STACK_R_ADDR
 	default 0x04000000 if !SPL_SHARES_INIT_SP_ADDR
 
arch/arm/mach-rockchip/spl.c +3 -0
index f4d29bbdd17..305373a161c 100644
@@ -61,6 +61,9 @@ u32 spl_boot_device(void)
 {
 	u32 boot_device = BOOT_DEVICE_MMC1;
 
+	if (IS_ENABLED(CONFIG_VPL))
+		return BOOT_DEVICE_VBE;
+
 #if defined(CONFIG_TARGET_CHROMEBOOK_JERRY) || \
 		defined(CONFIG_TARGET_CHROMEBIT_MICKEY) || \
 		defined(CONFIG_TARGET_CHROMEBOOK_MINNIE) || \
arch/arm/mach-rockchip/tpl.c +1 -1
index 6b880f19f84..cc794a7dca2 100644
@@ -84,5 +84,5 @@ int board_return_to_bootrom(struct spl_image_info *spl_image,
 
 u32 spl_boot_device(void)
 {
-	return BOOT_DEVICE_BOOTROM;
+	return IS_ENABLED(CONFIG_VPL) ? BOOT_DEVICE_VBE : BOOT_DEVICE_BOOTROM;
 }
arch/arm/mach-rockchip/u-boot-vpl-v8.lds new file +107 -0

107 lines not on this page · raw message

arch/arm/mach-rockchip/vpl.c new file +53 -0

53 lines not on this page · raw message

common/spl/Kconfig +1 -0
index 85566385c21..4e89b17815d 100644
@@ -572,6 +572,7 @@ config SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR
 	default 0x200 if ARCH_SOCFPGA || ARCH_AT91
 	default 0x300 if ARCH_ZYNQ || ARCH_KEYSTONE || OMAP34XX || \
 		         OMAP54XX || AM33XX || AM43XX || ARCH_K3
+	default 0x800 if ARCH_ROCKCHIP && VPL
 	default 0x4000 if ARCH_ROCKCHIP
 	default 0x822 if TARGET_SIFIVE_UNLEASHED || TARGET_SIFIVE_UNMATCHED
 	help
Signature · 1 line
2.43.0
#44 lore raw

PATCH v2 24/35 rockchip: Add symbols for spl_reloc

In reply to Simon Glass

Add various symbols so that this feature works as intended. This allows xPL to copy the relocating-jump code up to the top of memory, then use it to decompress and start the next phase.

---

(no changes since v1)

 arch/arm/mach-rockchip/u-boot-tpl-v8.lds | 13 +++++++++++++
 1 file changed, 13 insertions(+)
arch/arm/mach-rockchip/u-boot-tpl-v8.lds +13 -0
index 958a1b70aef..842bd4eb07f 100644
@@ -25,10 +25,21 @@ SECTIONS
 	__image_copy_start = ADDR(.text);
 	.text : {
 		. = ALIGN(8);
+		__image_copy_start = .;
 		CPUDIR/start.o (.text*)
+
+		/* put relocation code all together */
+		//. = . + 0xc0;
+		_rcode_start = .;
+		*(.text.rcode)
+		*(.text.rdata)
+		_rcode_end = .;
+
 		*(.text*)
 	}
 
+	_rcode_size = _rcode_end - _rcode_start;
+
 	.rodata : {
 		. = ALIGN(8);
 		*(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
@@ -48,6 +59,7 @@ SECTIONS
 	__image_copy_end = .;
 	_end = .;
 	_image_binary_end = .;
+	__image_copy_end = .;
 
 	.bss ALIGN(8) : {
 		__bss_start = .;
@@ -55,6 +67,7 @@ SECTIONS
 		. = ALIGN(8);
 		__bss_end = .;
 	}
+	__bss_size = __bss_end - __bss_start;
 
 	/DISCARD/ : { *(.dynsym) }
 	/DISCARD/ : { *(.dynstr*) }
Signature · 1 line
2.43.0
#45 lore raw

PATCH v2 25/35 rockchip: rk3399: Adjust initial TPL-stack to match SPL

In reply to Simon Glass

There doesn't seem to be a good reason to use a different value for TPL than SPL. Change the TPL value, since it allows a 256-byte bloblist to be safely located above the stack in all phases.

Note that for most boards, SDRAM init happens in TPL so the SPL stack ends up in DRAM, at address CONFIG_SPL_STACK_R_ADDR.

---

Changes in v2:
- Reword commit to mention comments from Jonas

 arch/arm/mach-rockchip/rk3399/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/mach-rockchip/rk3399/Kconfig +1 -1
index fc55b498111..8064b6286fc 100644
@@ -159,7 +159,7 @@ config TPL_LDSCRIPT
 	default "arch/arm/mach-rockchip/u-boot-tpl-v8.lds"
 
 config TPL_STACK
-        default 0xff8effff
+        default 0xff8eff00
 
 config TPL_TEXT_BASE
         default 0xff8c2000
Signature · 1 line
2.43.0
#46 lore raw

PATCH v2 26/35 rockchip: Allow SPL to set up SDRAM

In reply to Simon Glass

The current logic assumes that if TPL exists then it must be setting up the SDRAM. This is not true with VBE, so allow this to be controlled by whether CONFIG_TPL_RAM is enabled, or not.

---

(no changes since v1)

 arch/arm/mach-rockchip/tpl.c | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)
arch/arm/mach-rockchip/tpl.c +6 -4
index cc794a7dca2..2a261199179 100644
@@ -60,10 +60,12 @@ void board_init_f(ulong dummy)
 
 	tpl_board_init();
 
-	ret = uclass_get_device(UCLASS_RAM, 0, &dev);
-	if (ret) {
-		printf("DRAM init failed: %d\n", ret);
-		return;
+	if (CONFIG_IS_ENABLED(RAM)) {
+		ret = uclass_get_device(UCLASS_RAM, 0, &dev);
+		if (ret) {
+			printf("DRAM init failed: %d\n", ret);
+			return;
+		}
 	}
 }
 
Signature · 1 line
2.43.0
#47 lore raw

PATCH v2 27/35 rockchip: Add a generic-ddr3 rk3399 board

In reply to Simon Glass

This build-target is used to build an image which can run on multiple rk3399 boards, using VBE to boot.

To use it, the TPL binary for a particular board must be placed into the first part of the image. The rest of the image (i.e. VPL, SPL and U-Boot) are largely generic and can work on any supported board.

With VBE, memory-init happens in SPL so that this code is updatable in the field. Due to size constraints, the type of memory on the board is defined at build-time. So it is not possible to use the same VBE image on boards with different SDRAM (DDR3 vs LPDDR4 for example). This may become possible with newer boards with more SRAM.

---

Changes in v2:
- Rename to rk3399-generic-ddr3
- Update devicetree to match firefly-rk3399
- Use the firefly devicetree as the default for this board

 board/rockchip/evb_rk3399/MAINTAINERS |   6 ++
 configs/rk3399-generic-ddr3_defconfig | 125 ++++++++++++++++++++++++++
 2 files changed, 131 insertions(+)
 create mode 100644 configs/rk3399-generic-ddr3_defconfig
board/rockchip/evb_rk3399/MAINTAINERS +6 -0
index 8dab3fa70f5..73793c6ccbb 100644
@@ -89,3 +89,9 @@ M:	Jagan Teki <[email protected]>
 S:	Maintained
 F:	configs/rock-pi-n10-rk3399pro_defconfig
 F:	arch/arm/dts/rk3399pro-rock-pi-n10*
+
+RK3399-GENERIC-DDR3
+M:	Simon Glass <[email protected]>
+S:	Maintained
+F:	configs/rk3399-generic-ddr3_defconfig
+F:	arch/arm/dts/rockchip-vpl-u-boot.dtsi
configs/rk3399-generic-ddr3_defconfig new file +125 -0

125 lines not on this page · raw message

Signature · 1 line
2.43.0
#48 lore raw

PATCH v2 28/35 rockchip: Add documentation for VBE

In reply to Simon Glass

Now that VBE is running at a basic level on rk3399, add mention of it in the documentation.

---

(no changes since v1)

 doc/board/rockchip/rockchip.rst | 13 +++++++++++++
 1 file changed, 13 insertions(+)
doc/board/rockchip/rockchip.rst +13 -0
index 1407080f1f4..73d7c7de923 100644
@@ -490,6 +490,19 @@ config-flash.ini:
         [OUTPUT]
         PATH=RK30xxLoader_uboot.bin
 
+Verified Boot for Embedded (VBE)
+--------------------------------
+
+VBE is supported on rk3399 at present, with SDRAM being set up in SPL. The full
+A/B/recovery flow is supported in U-Boot.
+
+To build this, use the rk3399-generic board, setting CONFIG_OF_LIST to the list
+of boards you want to support. All boards must use the same SDRAM type.
+
+VBE uses internal SRAM (IRAM) for the TPL, VPL and early SPL phases. The stack
+stop is near the top of this (0xff8eff00) with the 256-byte bloblist immediately
+following.
+
 TODO
 ----
 
Signature · 1 line
2.43.0
#49 lore raw

PATCH v2 29/35 gitlab: Add an VBE board to the sjg lab

In reply to Simon Glass

Add a rockchip rk3399 board which runs Verified Boot for Embedded.

---

(no changes since v1)

 .gitlab-ci.yml | 6 ++++++
 1 file changed, 6 insertions(+)
.gitlab-ci.yml +6 -0
index 8c49d5b0a79..a9daa7bb84e 100644
@@ -745,3 +745,9 @@ zybo:
   variables:
     ROLE: zybo
   <<: *lab_dfn
+
+# Firefly-RK3399 board running the rk3399-generic build
+vbe:
+  variables:
+    ROLE: vbe
+  <<: *lab_dfn
Signature · 1 line
2.43.0
#50 lore raw

PATCH v2 30/35 rockchip: Set the skip-at-start property correctly

In reply to Simon Glass

The rockchip image is written to the media at block 64, which is a 32K offset, so set the skip-at-start property to 0x8000

Update CONFIG_SPL_PAD_TO to point to the offset in the image, since Binman is dealing with the 'missing' 32K now.

---

Changes in v2:
- Move this patch to the end of the series
- Drop 0x8000 offset for SPI

 arch/arm/dts/rockchip-u-boot.dtsi             | 1 +
 configs/anbernic-rgxx3-rk3566_defconfig       | 2 +-
 configs/bpi-r2-pro-rk3568_defconfig           | 2 +-
 configs/chromebit_mickey_defconfig            | 2 +-
 configs/chromebook_bob_defconfig              | 2 +-
 configs/chromebook_jerry_defconfig            | 2 +-
 configs/chromebook_kevin_defconfig            | 2 +-
 configs/chromebook_minnie_defconfig           | 2 +-
 configs/chromebook_speedy_defconfig           | 2 +-
 configs/cm3588-nas-rk3588_defconfig           | 2 +-
 configs/coolpi-4b-rk3588s_defconfig           | 2 +-
 configs/coolpi-cm5-evb-rk3588_defconfig       | 2 +-
 configs/coolpi-cm5-genbook-rk3588_defconfig   | 2 +-
 configs/eaidk-610-rk3399_defconfig            | 2 +-
 configs/evb-px30_defconfig                    | 2 +-
 configs/evb-px5_defconfig                     | 2 +-
 configs/evb-rk3036_defconfig                  | 2 +-
 configs/evb-rk3229_defconfig                  | 2 +-
 configs/evb-rk3288_defconfig                  | 2 +-
 configs/evb-rk3308_defconfig                  | 2 +-
 configs/evb-rk3328_defconfig                  | 2 +-
 configs/evb-rk3399_defconfig                  | 2 +-
 configs/evb-rk3568_defconfig                  | 2 +-
 configs/evb-rk3588_defconfig                  | 2 +-
 configs/ficus-rk3399_defconfig                | 2 +-
 configs/firefly-px30_defconfig                | 2 +-
 configs/firefly-rk3288_defconfig              | 2 +-
 configs/firefly-rk3399_defconfig              | 2 +-
 configs/generic-rk3568_defconfig              | 2 +-
 configs/generic-rk3588_defconfig              | 2 +-
 configs/jaguar-rk3588_defconfig               | 2 +-
 configs/khadas-edge-captain-rk3399_defconfig  | 2 +-
 configs/khadas-edge-rk3399_defconfig          | 2 +-
 configs/khadas-edge-v-rk3399_defconfig        | 2 +-
 configs/khadas-edge2-rk3588s_defconfig        | 2 +-
 configs/kylin-rk3036_defconfig                | 2 +-
 configs/leez-rk3399_defconfig                 | 2 +-
 configs/lubancat-2-rk3568_defconfig           | 2 +-
 configs/miqi-rk3288_defconfig                 | 2 +-
 configs/mk808_defconfig                       | 2 +-
 configs/nanopc-t4-rk3399_defconfig            | 2 +-
 configs/nanopc-t6-rk3588_defconfig            | 2 +-
 configs/nanopi-m4-2gb-rk3399_defconfig        | 2 +-
 configs/nanopi-m4-rk3399_defconfig            | 2 +-
 configs/nanopi-m4b-rk3399_defconfig           | 2 +-
 configs/nanopi-neo4-rk3399_defconfig          | 2 +-
 configs/nanopi-r2c-plus-rk3328_defconfig      | 2 +-
 configs/nanopi-r2c-rk3328_defconfig           | 2 +-
 configs/nanopi-r2s-plus-rk3328_defconfig      | 2 +-
 configs/nanopi-r2s-rk3328_defconfig           | 2 +-
 configs/nanopi-r3s-rk3566_defconfig           | 2 +-
 configs/nanopi-r4s-rk3399_defconfig           | 2 +-
 configs/nanopi-r5c-rk3568_defconfig           | 2 +-
 configs/nanopi-r5s-rk3568_defconfig           | 2 +-
 configs/nanopi-r6c-rk3588s_defconfig          | 2 +-
 configs/nanopi-r6s-rk3588s_defconfig          | 2 +-
 configs/neu2-io-rv1126_defconfig              | 2 +-
 configs/neu6a-io-rk3588_defconfig             | 2 +-
 configs/neu6b-io-rk3588_defconfig             | 2 +-
 configs/nova-rk3588s_defconfig                | 2 +-
 configs/odroid-go2_defconfig                  | 2 +-
 configs/odroid-m1-rk3568_defconfig            | 2 +-
 configs/odroid-m1s-rk3566_defconfig           | 2 +-
 configs/odroid-m2-rk3588s_defconfig           | 2 +-
 configs/orangepi-3b-rk3566_defconfig          | 2 +-
 configs/orangepi-5-plus-rk3588_defconfig      | 2 +-
 configs/orangepi-5-rk3588s_defconfig          | 2 +-
 configs/orangepi-r1-plus-lts-rk3328_defconfig | 2 +-
 configs/orangepi-r1-plus-rk3328_defconfig     | 2 +-
 configs/orangepi-rk3399_defconfig             | 2 +-
 configs/phycore-rk3288_defconfig              | 2 +-
 configs/pinebook-pro-rk3399_defconfig         | 2 +-
 configs/pinephone-pro-rk3399_defconfig        | 2 +-
 configs/pinetab2-rk3566_defconfig             | 2 +-
 configs/popmetal-rk3288_defconfig             | 2 +-
 configs/powkiddy-x55-rk3566_defconfig         | 2 +-
 configs/puma-rk3399_defconfig                 | 2 +-
 configs/px30-core-ctouch2-of10-px30_defconfig | 2 +-
 configs/px30-core-ctouch2-px30_defconfig      | 2 +-
 configs/px30-core-edimm2.2-px30_defconfig     | 2 +-
 configs/qnap-ts433-rk3568_defconfig           | 2 +-
 configs/quartz64-a-rk3566_defconfig           | 2 +-
 configs/quartz64-b-rk3566_defconfig           | 2 +-
 configs/quartzpro64-rk3588_defconfig          | 2 +-
 configs/radxa-cm3-io-rk3566_defconfig         | 2 +-
 configs/radxa-e25-rk3568_defconfig            | 2 +-
 configs/radxa-zero-3-rk3566_defconfig         | 2 +-
 configs/rk3399-generic-ddr3_defconfig         | 2 +-
 configs/roc-cc-rk3308_defconfig               | 2 +-
 configs/roc-cc-rk3328_defconfig               | 2 +-
 configs/roc-pc-mezzanine-rk3399_defconfig     | 2 +-
 configs/roc-pc-rk3399_defconfig               | 2 +-
 configs/rock-3a-rk3568_defconfig              | 2 +-
 configs/rock-3b-rk3568_defconfig              | 2 +-
 configs/rock-3c-rk3566_defconfig              | 2 +-
 configs/rock-4c-plus-rk3399_defconfig         | 2 +-
 configs/rock-4se-rk3399_defconfig             | 2 +-
 configs/rock-5-itx-rk3588_defconfig           | 2 +-
 configs/rock-5c-rk3588s_defconfig             | 2 +-
 configs/rock-pi-4-rk3399_defconfig            | 2 +-
 configs/rock-pi-4c-rk3399_defconfig           | 2 +-
 configs/rock-pi-e-rk3328_defconfig            | 2 +-
 configs/rock-pi-e-v3-rk3328_defconfig         | 2 +-
 configs/rock-pi-n10-rk3399pro_defconfig       | 2 +-
 configs/rock-pi-n8-rk3288_defconfig           | 2 +-
 configs/rock-pi-s-rk3308_defconfig            | 2 +-
 configs/rock-s0-rk3308_defconfig              | 2 +-
 configs/rock2_defconfig                       | 2 +-
 configs/rock5a-rk3588s_defconfig              | 2 +-
 configs/rock5b-rk3588_defconfig               | 2 +-
 configs/rock64-rk3328_defconfig               | 2 +-
 configs/rock960-rk3399_defconfig              | 2 +-
 configs/rock_defconfig                        | 2 +-
 configs/rockpro64-rk3399_defconfig            | 2 +-
 configs/sige7-rk3588_defconfig                | 2 +-
 configs/sonoff-ihost-rv1126_defconfig         | 2 +-
 configs/soquartz-blade-rk3566_defconfig       | 2 +-
 configs/soquartz-cm4-rk3566_defconfig         | 2 +-
 configs/soquartz-model-a-rk3566_defconfig     | 2 +-
 configs/tiger-rk3588_defconfig                | 2 +-
 configs/tinker-rk3288_defconfig               | 2 +-
 configs/tinker-s-rk3288_defconfig             | 2 +-
 configs/toybrick-rk3588_defconfig             | 2 +-
 configs/turing-rk1-rk3588_defconfig           | 2 +-
 configs/vyasa-rk3288_defconfig                | 2 +-
 125 files changed, 125 insertions(+), 124 deletions(-)
arch/arm/dts/rockchip-u-boot.dtsi +1 -0
index 0d59aad86bf..937d5a81742 100644
@@ -201,6 +201,7 @@
 	simple-bin {
 		filename = "u-boot-rockchip.bin";
 		pad-byte = <0xff>;
+		skip-at-start = <0x8000>;
 
 #ifndef CONFIG_VPL
 		mkimage {
configs/anbernic-rgxx3-rk3566_defconfig +1 -1
index 14c97b4c5bf..972d4c71b14 100644
@@ -28,7 +28,7 @@ CONFIG_BOARD_TYPES=y
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_BOARD_RNG_SEED=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_BOARD_INIT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y
configs/bpi-r2-pro-rk3568_defconfig +1 -1
index d84ea2f955f..e5eaf7f6449 100644
@@ -19,7 +19,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-bpi-r2-pro.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_SYS_PROMPT="BPI-R2PRO> "
configs/chromebit_mickey_defconfig +1 -1
index d834c1886a5..fe85ba2f50d 100644
@@ -36,7 +36,7 @@ CONFIG_LOG=y
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_BOARD_EARLY_INIT_R=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
configs/chromebook_bob_defconfig +1 -1
index 52b40903e3f..ba6b2691148 100644
@@ -40,7 +40,7 @@ CONFIG_BLOBLIST=y
 CONFIG_BLOBLIST_ADDR=0x100000
 CONFIG_BLOBLIST_SIZE=0x1000
 CONFIG_SPL_MAX_SIZE=0x1e000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_HANDOFF=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
configs/chromebook_jerry_defconfig +1 -1
index f4b9caeb34f..d268e55f083 100644
@@ -35,7 +35,7 @@ CONFIG_LOG=y
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_BOARD_EARLY_INIT_R=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
configs/chromebook_kevin_defconfig +1 -1
index aff097624ef..742f66beff6 100644
@@ -41,7 +41,7 @@ CONFIG_BLOBLIST=y
 CONFIG_BLOBLIST_ADDR=0x100000
 CONFIG_BLOBLIST_SIZE=0x1000
 CONFIG_SPL_MAX_SIZE=0x1e000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_HANDOFF=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
configs/chromebook_minnie_defconfig +1 -1
index 3a0be3078ab..a31052ca4f8 100644
@@ -36,7 +36,7 @@ CONFIG_LOG=y
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_BOARD_EARLY_INIT_R=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
configs/chromebook_speedy_defconfig +1 -1
index 78ab62c3392..fed4b1d9bde 100644
@@ -36,7 +36,7 @@ CONFIG_LOG=y
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_BOARD_EARLY_INIT_R=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
configs/cm3588-nas-rk3588_defconfig +1 -1
index fd0a32d6d79..abd60abc177 100644
@@ -21,7 +21,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-friendlyelec-cm3588-nas.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/coolpi-4b-rk3588s_defconfig +1 -1
index ea985b81670..7b90bc59afb 100644
@@ -27,7 +27,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588s-coolpi-4b.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/coolpi-cm5-evb-rk3588_defconfig +1 -1
index 58ffe7baf5f..10d07332ad6 100644
@@ -27,7 +27,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-coolpi-cm5-evb.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/coolpi-cm5-genbook-rk3588_defconfig +1 -1
index 3eb5dc968af..ab867e758cc 100644
@@ -28,7 +28,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-coolpi-cm5-genbook.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/eaidk-610-rk3399_defconfig +1 -1
index 8f9a76157f1..7f3215628a4 100644
@@ -15,7 +15,7 @@ CONFIG_DEBUG_UART=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-eaidk-610.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/evb-px30_defconfig +1 -1
index 50dd29fcb01..9335dfd1dad 100644
@@ -25,7 +25,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/px30-evb.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_MISC_INIT_R=y
 CONFIG_SPL_MAX_SIZE=0x20000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_BOOTROM_SUPPORT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
configs/evb-px5_defconfig +1 -1
index c9262417139..9dcf6badc78 100644
@@ -41,7 +41,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3368-px5-evb.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_BOOTROM_SUPPORT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
configs/evb-rk3036_defconfig +1 -1
index 4e471f0ebb3..a1d9590c841 100644
@@ -28,7 +28,7 @@ CONFIG_DEFAULT_FDT_FILE="rk3036-evb.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 # CONFIG_SPL_FRAMEWORK is not set
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 CONFIG_CMD_GPT=y
 CONFIG_CMD_I2C=y
configs/evb-rk3229_defconfig +1 -1
index 3cbc22662a6..030abfc6b6e 100644
@@ -28,7 +28,7 @@ CONFIG_DEFAULT_FDT_FILE="rk3229-evb.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x100000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_CMD_GPT=y
configs/evb-rk3288_defconfig +1 -1
index f6b72a2b7a0..024127944c2 100644
@@ -33,7 +33,7 @@ CONFIG_USE_PREBOOT=y
 CONFIG_DEFAULT_FDT_FILE="rk3288-evb-rk808.dtb"
 CONFIG_SILENT_CONSOLE=y
 CONFIG_DISPLAY_BOARDINFO_LATE=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
configs/evb-rk3308_defconfig +1 -1
index c8e1753b281..f07234a5024 100644
@@ -17,7 +17,7 @@ CONFIG_FIT_VERBOSE=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3308-evb.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_CMD_GPIO=y
 CONFIG_CMD_GPT=y
configs/evb-rk3328_defconfig +1 -1
index fd528535838..cb4a5386033 100644
@@ -22,7 +22,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3328-evb.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
configs/evb-rk3399_defconfig +1 -1
index 9481dfae7e4..8f1b7570a35 100644
@@ -16,7 +16,7 @@ CONFIG_DEBUG_UART=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-evb.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/evb-rk3568_defconfig +1 -1
index a068bc6846c..9ab3583b4a0 100644
@@ -18,7 +18,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-evb1-v10.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/evb-rk3588_defconfig +1 -1
index 3d4d2747145..9ea4ea1c6ab 100644
@@ -19,7 +19,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-evb1-v10.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/ficus-rk3399_defconfig +1 -1
index b32ca726b6c..b750df55e68 100644
@@ -17,7 +17,7 @@ CONFIG_AHCI=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-ficus.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/firefly-px30_defconfig +1 -1
index 7398d06274f..eab55f669cf 100644
@@ -26,7 +26,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/px30-firefly.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_MISC_INIT_R=y
 CONFIG_SPL_MAX_SIZE=0x20000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_BOOTROM_SUPPORT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
configs/firefly-rk3288_defconfig +1 -1
index d8a671b7a8a..2205ec2f3e5 100644
@@ -25,7 +25,7 @@ CONFIG_SPL_LOAD_FIT=y
 CONFIG_LEGACY_IMAGE_FORMAT=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3288-firefly.dtb"
 CONFIG_MISC_INIT_R=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_CMD_GPIO=y
 CONFIG_CMD_GPT=y
configs/firefly-rk3399_defconfig +1 -1
index 3871627318b..aaea58b6b4a 100644
@@ -17,7 +17,7 @@ CONFIG_DEBUG_UART=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-firefly.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/generic-rk3568_defconfig +1 -1
index f79f0e84400..10d7616296f 100644
@@ -23,7 +23,7 @@ CONFIG_LEGACY_IMAGE_FORMAT=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-generic.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/generic-rk3588_defconfig +1 -1
index 51e31dce3a9..b77f2a76dd6 100644
@@ -19,7 +19,7 @@ CONFIG_LEGACY_IMAGE_FORMAT=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-generic.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/jaguar-rk3588_defconfig +1 -1
index 6e853991d1d..01cf1bb90c9 100644
@@ -27,7 +27,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-jaguar.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_CYCLIC=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 # CONFIG_BOOTM_NETBSD is not set
configs/khadas-edge-captain-rk3399_defconfig +1 -1
index 89611a0535e..0cac100784f 100644
@@ -22,7 +22,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-khadas-edge-captain.dtb"
 CONFIG_SYS_PBSIZE=1048
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0xE0000
configs/khadas-edge-rk3399_defconfig +1 -1
index 3816f4327a6..5b5e39d8306 100644
@@ -21,7 +21,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-khadas-edge.dtb"
 CONFIG_SYS_PBSIZE=1048
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0xE0000
configs/khadas-edge-v-rk3399_defconfig +1 -1
index 35e20942572..07bf6bc595d 100644
@@ -22,7 +22,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-khadas-edge-v.dtb"
 CONFIG_SYS_PBSIZE=1048
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0xE0000
configs/khadas-edge2-rk3588s_defconfig +1 -1
index 208c72ca425..b55f88d64f8 100644
@@ -24,7 +24,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588s-khadas-edge2.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SEPARATE_BSS=y
 CONFIG_SPL_MMC_WRITE=y
configs/kylin-rk3036_defconfig +1 -1
index 1ebb703c6fa..995d2af74a0 100644
@@ -30,7 +30,7 @@ CONFIG_DEFAULT_FDT_FILE="rk3036-kylin.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 # CONFIG_SPL_FRAMEWORK is not set
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 CONFIG_CMD_GPT=y
 CONFIG_CMD_I2C=y
configs/leez-rk3399_defconfig +1 -1
index 57b097377fa..ac4c8b06f2f 100644
@@ -15,7 +15,7 @@ CONFIG_DEBUG_UART=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-leez-p710.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/lubancat-2-rk3568_defconfig +1 -1
index 46cc3c03fff..51f1f6ad5f8 100644
@@ -19,7 +19,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-lubancat-2.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/miqi-rk3288_defconfig +1 -1
index 166468fd4e7..21747abe2bc 100644
@@ -24,7 +24,7 @@ CONFIG_SPL_LOAD_FIT=y
 CONFIG_LEGACY_IMAGE_FORMAT=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3288-miqi.dtb"
 CONFIG_MISC_INIT_R=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_CMD_GPIO=y
 CONFIG_CMD_GPT=y
configs/mk808_defconfig +1 -1
index 8c7f4deb843..2b1d5b88d18 100644
@@ -43,7 +43,7 @@ CONFIG_SYS_PBSIZE=276
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_BOARD_LATE_INIT=y
 CONFIG_SPL_MAX_SIZE=0x32000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
 CONFIG_SPL_SEPARATE_BSS=y
configs/nanopc-t4-rk3399_defconfig +1 -1
index 26c12c51078..95276602a42 100644
@@ -17,7 +17,7 @@ CONFIG_DEBUG_UART=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-nanopc-t4.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/nanopc-t6-rk3588_defconfig +1 -1
index 772b7df1555..31be93dc2e8 100644
@@ -27,7 +27,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-nanopc-t6.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/nanopi-m4-2gb-rk3399_defconfig +1 -1
index d24b7bc6d17..fa1839baa96 100644
@@ -18,7 +18,7 @@ CONFIG_AHCI=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-nanopi-m4-2gb.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/nanopi-m4-rk3399_defconfig +1 -1
index da3e44af841..ae84be9f5b9 100644
@@ -18,7 +18,7 @@ CONFIG_AHCI=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-nanopi-m4.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/nanopi-m4b-rk3399_defconfig +1 -1
index 247056ab58b..0815534618b 100644
@@ -18,7 +18,7 @@ CONFIG_AHCI=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-nanopi-m4b.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/nanopi-neo4-rk3399_defconfig +1 -1
index 305877d2079..5ac47919e0a 100644
@@ -16,7 +16,7 @@ CONFIG_DEBUG_UART=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-nanopi-neo4.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/nanopi-r2c-plus-rk3328_defconfig +1 -1
index bef1e22d644..c867c044b0a 100644
@@ -23,7 +23,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3328-nanopi-r2c-plus.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y
 CONFIG_SPL_ATF=y
configs/nanopi-r2c-rk3328_defconfig +1 -1
index 4d66a76c7dc..37648c87e87 100644
@@ -23,7 +23,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3328-nanopi-r2c.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y
 CONFIG_SPL_ATF=y
configs/nanopi-r2s-plus-rk3328_defconfig +1 -1
index 3a75566ed4d..05a3e51dfb6 100644
@@ -23,7 +23,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3328-nanopi-r2s-plus.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y
 CONFIG_SPL_ATF=y
configs/nanopi-r2s-rk3328_defconfig +1 -1
index 2b9193d1ff5..ef458b221be 100644
@@ -23,7 +23,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3328-nanopi-r2s.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y
 CONFIG_SPL_ATF=y
configs/nanopi-r3s-rk3566_defconfig +1 -1
index 870613f690a..1b4a89637e4 100644
@@ -20,7 +20,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-nanopi-r3s.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/nanopi-r4s-rk3399_defconfig +1 -1
index a6dafe3d9eb..e60888a529f 100644
@@ -16,7 +16,7 @@ CONFIG_DEBUG_UART=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-nanopi-r4s.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/nanopi-r5c-rk3568_defconfig +1 -1
index 4a43b17ccb1..036e9158929 100644
@@ -20,7 +20,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-nanopi-r5c.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/nanopi-r5s-rk3568_defconfig +1 -1
index a60d229fbbf..8abd77879f7 100644
@@ -20,7 +20,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-nanopi-r5s.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/nanopi-r6c-rk3588s_defconfig +1 -1
index c4de5518a72..eaef4d23a33 100644
@@ -21,7 +21,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588s-nanopi-r6c.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/nanopi-r6s-rk3588s_defconfig +1 -1
index 2726729b9ac..3318b07736f 100644
@@ -21,7 +21,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588s-nanopi-r6s.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/neu2-io-rv1126_defconfig +1 -1
index 18230859b18..431803e1e64 100644
@@ -18,7 +18,7 @@ CONFIG_FIT_VERBOSE=y
 CONFIG_DEFAULT_FDT_FILE="rv1126-edgeble-neu2-io.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
configs/neu6a-io-rk3588_defconfig +1 -1
index 291e0d26d42..cbcf1434d5e 100644
@@ -19,7 +19,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-edgeble-neu6a-io.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPT=y
configs/neu6b-io-rk3588_defconfig +1 -1
index 4e22852f23c..6f4b35510a6 100644
@@ -19,7 +19,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-edgeble-neu6b-io.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPT=y
configs/nova-rk3588s_defconfig +1 -1
index fb30dfd1db8..d25405fbb72 100644
@@ -20,7 +20,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588s-indiedroid-nova.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/odroid-go2_defconfig +1 -1
index 492802dddae..69bd559c5a9 100644
@@ -29,7 +29,7 @@ CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_BOARD_LATE_INIT=y
 CONFIG_MISC_INIT_R=y
 CONFIG_SPL_MAX_SIZE=0x20000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_BOOTROM_SUPPORT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_I2C=y
configs/odroid-m1-rk3568_defconfig +1 -1
index a8e8a8781e1..8e0e2353bf6 100644
@@ -27,7 +27,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-odroid-m1.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x100000
configs/odroid-m1s-rk3566_defconfig +1 -1
index 39e815ad317..0078a33dbc7 100644
@@ -21,7 +21,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-odroid-m1s.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/odroid-m2-rk3588s_defconfig +1 -1
index 4c3fa8500d8..0bdc262bad0 100644
@@ -21,7 +21,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588s-odroid-m2.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/orangepi-3b-rk3566_defconfig +1 -1
index 2181c9caf58..83ca7bb27b5 100644
@@ -28,7 +28,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-orangepi-3b.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/orangepi-5-plus-rk3588_defconfig +1 -1
index 9050fceda45..214d8363313 100644
@@ -28,7 +28,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-orangepi-5-plus.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/orangepi-5-rk3588s_defconfig +1 -1
index 6e2ff7d338a..844dd22a1a8 100644
@@ -27,7 +27,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588s-orangepi-5.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/orangepi-r1-plus-lts-rk3328_defconfig +1 -1
index 6d5d8b9dcc9..0874a013046 100644
@@ -26,7 +26,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3328-orangepi-r1-plus-lts.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y
 CONFIG_SPL_SPI_LOAD=y
configs/orangepi-r1-plus-rk3328_defconfig +1 -1
index b382f9b9f18..1bd51675cc4 100644
@@ -26,7 +26,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3328-orangepi-r1-plus.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y
 CONFIG_SPL_SPI_LOAD=y
configs/orangepi-rk3399_defconfig +1 -1
index fdf3d698939..1d1cf412b43 100644
@@ -16,7 +16,7 @@ CONFIG_DEBUG_UART=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-orangepi.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/phycore-rk3288_defconfig +1 -1
index ff03a59b48d..ac2944160b8 100644
@@ -31,7 +31,7 @@ CONFIG_DEFAULT_FDT_FILE="rk3288-phycore-rdk.dtb"
 CONFIG_SILENT_CONSOLE=y
 CONFIG_CONSOLE_MUX=y
 CONFIG_DISPLAY_BOARDINFO_LATE=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
 CONFIG_CMD_GPIO=y
configs/pinebook-pro-rk3399_defconfig +1 -1
index dfa927ccb17..195bc01152f 100644
@@ -25,7 +25,7 @@ CONFIG_USE_PREBOOT=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-pinebook-pro.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0xE0000
configs/pinephone-pro-rk3399_defconfig +1 -1
index 5e16749ba7d..d5a70015ed6 100644
@@ -23,7 +23,7 @@ CONFIG_USE_PREBOOT=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-pinephone-pro.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0xE0000
configs/pinetab2-rk3566_defconfig +1 -1
index 45e63b42d19..cf10abc4c8f 100644
@@ -27,7 +27,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-pinetab2-v2.0.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_I2C=y
 CONFIG_SPL_POWER=y
configs/popmetal-rk3288_defconfig +1 -1
index ae7869ae5fa..4c29afe924e 100644
@@ -30,7 +30,7 @@ CONFIG_DEFAULT_FDT_FILE="rk3288-popmetal.dtb"
 CONFIG_SILENT_CONSOLE=y
 CONFIG_CONSOLE_MUX=y
 CONFIG_DISPLAY_BOARDINFO_LATE=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
 CONFIG_CMD_GPIO=y
configs/powkiddy-x55-rk3566_defconfig +1 -1
index 85280839889..3b96c8d3c07 100644
@@ -18,7 +18,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-powkiddy-x55.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/puma-rk3399_defconfig +1 -1
index 7a180b14130..55e15612260 100644
@@ -23,7 +23,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-puma-haikou.dtb"
 CONFIG_CONSOLE_MUX=y
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x2e000
-CONFIG_SPL_PAD_TO=0x38000
+CONFIG_SPL_PAD_TO=0x40000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR=0x200
 CONFIG_SPL_I2C=y
configs/px30-core-ctouch2-of10-px30_defconfig +1 -1
index 97a6d45f39b..23743683aa8 100644
@@ -25,7 +25,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/px30-engicam-px30-core-ctouch2-of10.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_MISC_INIT_R=y
 CONFIG_SPL_MAX_SIZE=0x20000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_BOOTROM_SUPPORT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
configs/px30-core-ctouch2-px30_defconfig +1 -1
index 0d20546a746..c3870f70d67 100644
@@ -25,7 +25,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/px30-engicam-px30-core-ctouch2.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_MISC_INIT_R=y
 CONFIG_SPL_MAX_SIZE=0x20000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_BOOTROM_SUPPORT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
configs/px30-core-edimm2.2-px30_defconfig +1 -1
index 6d7ec8f3598..1c0a1c63488 100644
@@ -25,7 +25,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/px30-engicam-px30-core-edimm2.2.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_MISC_INIT_R=y
 CONFIG_SPL_MAX_SIZE=0x20000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_BOOTROM_SUPPORT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
configs/qnap-ts433-rk3568_defconfig +1 -1
index ceef0d25dc0..cb70e2bcdaf 100644
@@ -22,7 +22,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-qnap-ts433.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/quartz64-a-rk3566_defconfig +1 -1
index fe3fa37611a..2578b5d65a0 100644
@@ -28,7 +28,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-quartz64-a.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y
 CONFIG_SPL_SPI_LOAD=y
configs/quartz64-b-rk3566_defconfig +1 -1
index 929736f76af..d8e7e3036a8 100644
@@ -27,7 +27,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-quartz64-b.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/quartzpro64-rk3588_defconfig +1 -1
index ade7be27e92..40dd6ff84bf 100644
@@ -22,7 +22,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-quartzpro64.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/radxa-cm3-io-rk3566_defconfig +1 -1
index 2655fdc3170..690c56ec3b2 100644
@@ -18,7 +18,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-radxa-cm3-io.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/radxa-e25-rk3568_defconfig +1 -1
index 4df594ddc01..9d63d04034c 100644
@@ -21,7 +21,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-radxa-e25.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/radxa-zero-3-rk3566_defconfig +1 -1
index 5989b07ad79..d75ae675b93 100644
@@ -20,7 +20,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-radxa-zero-3w.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y
 CONFIG_SPL_ATF=y
configs/rk3399-generic-ddr3_defconfig +1 -1
index 82e576f188c..6772227cf83 100644
@@ -42,7 +42,7 @@ CONFIG_BLOBLIST_SIZE=0x100
 CONFIG_SPL_BLOBLIST_RELOC=y
 CONFIG_SPL_BLOBLIST_RELOC_ADDR=0x00100000
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
 CONFIG_SPL_HAVE_INIT_STACK=y
 # CONFIG_SPL_SEPARATE_BSS is not set
configs/roc-cc-rk3308_defconfig +1 -1
index fb81d3bccfb..b08d0a4c1fb 100644
@@ -17,7 +17,7 @@ CONFIG_FIT_VERBOSE=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3308-roc-cc.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_CMD_GPIO=y
 CONFIG_CMD_GPT=y
configs/roc-cc-rk3328_defconfig +1 -1
index 183332ab7ce..80a44449328 100644
@@ -22,7 +22,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3328-roc-cc.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y
 CONFIG_SPL_ATF=y
configs/roc-pc-mezzanine-rk3399_defconfig +1 -1
index 3ab5fd69c62..bac62d3b8a0 100644
@@ -25,7 +25,7 @@ CONFIG_DEBUG_UART=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-roc-pc-mezzanine.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ENV_SUPPORT=y
 CONFIG_SPL_SPI_LOAD=y
configs/roc-pc-rk3399_defconfig +1 -1
index 0ef86748778..dad038e6020 100644
@@ -24,7 +24,7 @@ CONFIG_DEBUG_UART=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-roc-pc.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ENV_SUPPORT=y
 CONFIG_SPL_SPI_LOAD=y
configs/rock-3a-rk3568_defconfig +1 -1
index 733ce631457..ebb24491205 100644
@@ -26,7 +26,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-rock-3a.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/rock-3b-rk3568_defconfig +1 -1
index 2023feb36c2..349a20349b0 100644
@@ -26,7 +26,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-rock-3b.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/rock-3c-rk3566_defconfig +1 -1
index 2528c7c639c..db8f6163627 100644
@@ -26,7 +26,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-rock-3c.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/rock-4c-plus-rk3399_defconfig +1 -1
index 0c73a212ea1..97ad1c52c92 100644
@@ -23,7 +23,7 @@ CONFIG_EFI_CAPSULE_FIRMWARE_RAW=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rock-4c-plus.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0xE0000
configs/rock-4se-rk3399_defconfig +1 -1
index 3ae19692155..ed128429c8a 100644
@@ -25,7 +25,7 @@ CONFIG_EFI_CAPSULE_FIRMWARE_RAW=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rock-4se.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0xE0000
configs/rock-5-itx-rk3588_defconfig +1 -1
index d0dd1c20ece..47817435f67 100644
@@ -28,7 +28,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-rock-5-itx.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/rock-5c-rk3588s_defconfig +1 -1
index 59f9f25edcb..5089597da7e 100644
@@ -21,7 +21,7 @@ CONFIG_LEGACY_IMAGE_FORMAT=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588s-rock-5c.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_ADC=y
configs/rock-pi-4-rk3399_defconfig +1 -1
index f3a5c2c45f3..cb01181c651 100644
@@ -25,7 +25,7 @@ CONFIG_EFI_CAPSULE_FIRMWARE_RAW=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rock-pi-4a.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0xE0000
configs/rock-pi-4c-rk3399_defconfig +1 -1
index 9bda50c8c77..1cbd5972463 100644
@@ -25,7 +25,7 @@ CONFIG_EFI_CAPSULE_FIRMWARE_RAW=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rock-pi-4c.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0xE0000
configs/rock-pi-e-rk3328_defconfig +1 -1
index 52dad765a8a..532f420e544 100644
@@ -22,7 +22,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3328-rock-pi-e.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y
 CONFIG_SPL_ATF=y
configs/rock-pi-e-v3-rk3328_defconfig +1 -1
index 518ea4ebe51..fb2bc8cc9c9 100644
@@ -22,7 +22,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3328-rock-pi-e.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y
 CONFIG_SPL_ATF=y
configs/rock-pi-n10-rk3399pro_defconfig +1 -1
index a9c6d8a907a..4ae0ddd3059 100644
@@ -18,7 +18,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399pro-rock-pi-n10.dtb"
 # CONFIG_CONSOLE_MUX is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/rock-pi-n8-rk3288_defconfig +1 -1
index 92ffc72cd7a..c64e8f080a3 100644
@@ -29,7 +29,7 @@ CONFIG_DEBUG_UART=y
 CONFIG_USE_PREBOOT=y
 CONFIG_SILENT_CONSOLE=y
 CONFIG_DISPLAY_BOARDINFO_LATE=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
 CONFIG_CMD_SPL=y
configs/rock-pi-s-rk3308_defconfig +1 -1
index 4b08af309b1..3c357b5cec6 100644
@@ -17,7 +17,7 @@ CONFIG_FIT_VERBOSE=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3308-rock-pi-s.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_CMD_GPIO=y
 CONFIG_CMD_GPT=y
configs/rock-s0-rk3308_defconfig +1 -1
index 0a46e7bb187..8d7ed5d1434 100644
@@ -17,7 +17,7 @@ CONFIG_FIT_VERBOSE=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3308-rock-s0.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_CMD_GPIO=y
 CONFIG_CMD_GPT=y
configs/rock2_defconfig +1 -1
index b356df23ec6..4255e37c448 100644
@@ -30,7 +30,7 @@ CONFIG_DEFAULT_FDT_FILE="rk3288-rock2-square.dtb"
 CONFIG_SILENT_CONSOLE=y
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
 CONFIG_CMD_GPIO=y
configs/rock5a-rk3588s_defconfig +1 -1
index 9618d590009..2449f33abc5 100644
@@ -19,7 +19,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588s-rock-5a.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/rock5b-rk3588_defconfig +1 -1
index 47ee2109f8e..80781eef2d1 100644
@@ -29,7 +29,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-rock-5b.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000
configs/rock64-rk3328_defconfig +1 -1
index 6d00b52e62f..12e248c05c1 100644
@@ -25,7 +25,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3328-rock64.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y
 CONFIG_SPL_SPI_LOAD=y
configs/rock960-rk3399_defconfig +1 -1
index aebfa73459c..1c361b019b7 100644
@@ -16,7 +16,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rock960.dtb"
 CONFIG_SYS_PBSIZE=1052
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y
 CONFIG_TPL=y
configs/rock_defconfig +1 -1
index d2a84710cb0..09740abf55c 100644
@@ -30,7 +30,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3188-radxarock.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x7800
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
 CONFIG_CMD_I2C=y
configs/rockpro64-rk3399_defconfig +1 -1
index 75322073285..fdd80e72bf1 100644
@@ -23,7 +23,7 @@ CONFIG_DEBUG_UART=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rockpro64.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_SPI_LOAD=y
 CONFIG_SYS_SPI_U_BOOT_OFFS=0xE0000
configs/sige7-rk3588_defconfig +1 -1
index 8b033e22b84..c374ff8d337 100644
@@ -23,7 +23,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-armsom-sige7.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/sonoff-ihost-rv1126_defconfig +1 -1
index 78ca7a3859e..74deef49737 100644
@@ -19,7 +19,7 @@ CONFIG_SPL_LOAD_FIT=y
 CONFIG_DEFAULT_FDT_FILE="rv1126-sonoff-ihost.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
configs/soquartz-blade-rk3566_defconfig +1 -1
index a1a51b2c657..a29310ede62 100644
@@ -21,7 +21,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-soquartz-blade.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/soquartz-cm4-rk3566_defconfig +1 -1
index a8bca0eaccc..4652879be6c 100644
@@ -21,7 +21,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-soquartz-cm4.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/soquartz-model-a-rk3566_defconfig +1 -1
index f080d2e36d2..913cb87b12d 100644
@@ -21,7 +21,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-soquartz-model-a.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/tiger-rk3588_defconfig +1 -1
index f962ac416f3..a3952ff55da 100644
@@ -28,7 +28,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-tiger-haikou.dtb"
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_CYCLIC=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 # CONFIG_BOOTM_NETBSD is not set
configs/tinker-rk3288_defconfig +1 -1
index bc5379d4343..fd7f60008d6 100644
@@ -24,7 +24,7 @@ CONFIG_SPL_LOAD_FIT=y
 CONFIG_LEGACY_IMAGE_FORMAT=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3288-tinker.dtb"
 CONFIG_MISC_INIT_R=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_CMD_GPIO=y
 CONFIG_CMD_GPT=y
configs/tinker-s-rk3288_defconfig +1 -1
index f0c8cc5bbc1..240d8bd9b5f 100644
@@ -24,7 +24,7 @@ CONFIG_SPL_LOAD_FIT=y
 CONFIG_LEGACY_IMAGE_FORMAT=y
 CONFIG_DEFAULT_FDT_FILE="rockchip/rk3288-tinker-s.dtb"
 CONFIG_MISC_INIT_R=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_CMD_GPIO=y
 CONFIG_CMD_GPT=y
configs/toybrick-rk3588_defconfig +1 -1
index 5e70341c987..7da1b5cbc3b 100644
@@ -19,7 +19,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-toybrick-x0.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/turing-rk1-rk3588_defconfig +1 -1
index 0eddf15833c..73d7b32e300 100644
@@ -22,7 +22,7 @@ CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-turing-rk1.dtb"
 # CONFIG_DISPLAY_CPUINFO is not set
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_ATF=y
 CONFIG_CMD_GPIO=y
configs/vyasa-rk3288_defconfig +1 -1
index 3b4dc5b5699..d3b88269134 100644
@@ -30,7 +30,7 @@ CONFIG_USE_PREBOOT=y
 CONFIG_DEFAULT_FDT_FILE="rk3288-vyasa.dtb"
 CONFIG_SILENT_CONSOLE=y
 CONFIG_DISPLAY_BOARDINFO_LATE=y
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_NO_BSS_LIMIT=y
 # CONFIG_SPL_SHARES_INIT_SP_ADDR is not set
 CONFIG_SPL_OS_BOOT=y
Signature · 1 line
2.43.0
#51 lore raw

Re: [PATCH v2 30/35] rockchip: Set the skip-at-start property correctly

Hi Simon,

Quoted 5 lines · Simon Glass

The rockchip image is written to the media at block 64, which is a 32K offset, so set the skip-at-start property to 0x8000

Update CONFIG_SPL_PAD_TO to point to the offset in the image, since Binman is dealing with the 'missing' 32K now.

This confuses me, to me the image is the output binary image. And the offset in the image is what SPL_PAD_TO already is referring to.

The help for SPL_PAD_TO mention "Image offset to which the SPL should be padded before appending the SPL payload.".

I can be fine with changing it to payload location in storage, however do such mass change in a separate series and with a clear explanation why SPL_PAD_TO should mean the offset on storage and not offset in the output binary image written to storage.

With one patch that just add the skip-at-start prop and adjust to use <(CONFIG_SPL_PAD_TO + 0x8000)> for the offset prop. And put the mass change to defconfig in a separate patch.

Another option could possible be to use SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR in a calculation and drop use of the SPL_PAD_TO symbol.

Else this blocks others from adding new boards, and/or will break them if a defconfig was missed. With a separate series adding a new board can just reference the smaller series.

Regards,
Jonas

Quoted 160 lines

---

Changes in v2:
- Move this patch to the end of the series
- Drop 0x8000 offset for SPI

 arch/arm/dts/rockchip-u-boot.dtsi             | 1 +
 configs/anbernic-rgxx3-rk3566_defconfig       | 2 +-
 configs/bpi-r2-pro-rk3568_defconfig           | 2 +-
 configs/chromebit_mickey_defconfig            | 2 +-
 configs/chromebook_bob_defconfig              | 2 +-
 configs/chromebook_jerry_defconfig            | 2 +-
 configs/chromebook_kevin_defconfig            | 2 +-
 configs/chromebook_minnie_defconfig           | 2 +-
 configs/chromebook_speedy_defconfig           | 2 +-
 configs/cm3588-nas-rk3588_defconfig           | 2 +-
 configs/coolpi-4b-rk3588s_defconfig           | 2 +-
 configs/coolpi-cm5-evb-rk3588_defconfig       | 2 +-
 configs/coolpi-cm5-genbook-rk3588_defconfig   | 2 +-
 configs/eaidk-610-rk3399_defconfig            | 2 +-
 configs/evb-px30_defconfig                    | 2 +-
 configs/evb-px5_defconfig                     | 2 +-
 configs/evb-rk3036_defconfig                  | 2 +-
 configs/evb-rk3229_defconfig                  | 2 +-
 configs/evb-rk3288_defconfig                  | 2 +-
 configs/evb-rk3308_defconfig                  | 2 +-
 configs/evb-rk3328_defconfig                  | 2 +-
 configs/evb-rk3399_defconfig                  | 2 +-
 configs/evb-rk3568_defconfig                  | 2 +-
 configs/evb-rk3588_defconfig                  | 2 +-
 configs/ficus-rk3399_defconfig                | 2 +-
 configs/firefly-px30_defconfig                | 2 +-
 configs/firefly-rk3288_defconfig              | 2 +-
 configs/firefly-rk3399_defconfig              | 2 +-
 configs/generic-rk3568_defconfig              | 2 +-
 configs/generic-rk3588_defconfig              | 2 +-
 configs/jaguar-rk3588_defconfig               | 2 +-
 configs/khadas-edge-captain-rk3399_defconfig  | 2 +-
 configs/khadas-edge-rk3399_defconfig          | 2 +-
 configs/khadas-edge-v-rk3399_defconfig        | 2 +-
 configs/khadas-edge2-rk3588s_defconfig        | 2 +-
 configs/kylin-rk3036_defconfig                | 2 +-
 configs/leez-rk3399_defconfig                 | 2 +-
 configs/lubancat-2-rk3568_defconfig           | 2 +-
 configs/miqi-rk3288_defconfig                 | 2 +-
 configs/mk808_defconfig                       | 2 +-
 configs/nanopc-t4-rk3399_defconfig            | 2 +-
 configs/nanopc-t6-rk3588_defconfig            | 2 +-
 configs/nanopi-m4-2gb-rk3399_defconfig        | 2 +-
 configs/nanopi-m4-rk3399_defconfig            | 2 +-
 configs/nanopi-m4b-rk3399_defconfig           | 2 +-
 configs/nanopi-neo4-rk3399_defconfig          | 2 +-
 configs/nanopi-r2c-plus-rk3328_defconfig      | 2 +-
 configs/nanopi-r2c-rk3328_defconfig           | 2 +-
 configs/nanopi-r2s-plus-rk3328_defconfig      | 2 +-
 configs/nanopi-r2s-rk3328_defconfig           | 2 +-
 configs/nanopi-r3s-rk3566_defconfig           | 2 +-
 configs/nanopi-r4s-rk3399_defconfig           | 2 +-
 configs/nanopi-r5c-rk3568_defconfig           | 2 +-
 configs/nanopi-r5s-rk3568_defconfig           | 2 +-
 configs/nanopi-r6c-rk3588s_defconfig          | 2 +-
 configs/nanopi-r6s-rk3588s_defconfig          | 2 +-
 configs/neu2-io-rv1126_defconfig              | 2 +-
 configs/neu6a-io-rk3588_defconfig             | 2 +-
 configs/neu6b-io-rk3588_defconfig             | 2 +-
 configs/nova-rk3588s_defconfig                | 2 +-
 configs/odroid-go2_defconfig                  | 2 +-
 configs/odroid-m1-rk3568_defconfig            | 2 +-
 configs/odroid-m1s-rk3566_defconfig           | 2 +-
 configs/odroid-m2-rk3588s_defconfig           | 2 +-
 configs/orangepi-3b-rk3566_defconfig          | 2 +-
 configs/orangepi-5-plus-rk3588_defconfig      | 2 +-
 configs/orangepi-5-rk3588s_defconfig          | 2 +-
 configs/orangepi-r1-plus-lts-rk3328_defconfig | 2 +-
 configs/orangepi-r1-plus-rk3328_defconfig     | 2 +-
 configs/orangepi-rk3399_defconfig             | 2 +-
 configs/phycore-rk3288_defconfig              | 2 +-
 configs/pinebook-pro-rk3399_defconfig         | 2 +-
 configs/pinephone-pro-rk3399_defconfig        | 2 +-
 configs/pinetab2-rk3566_defconfig             | 2 +-
 configs/popmetal-rk3288_defconfig             | 2 +-
 configs/powkiddy-x55-rk3566_defconfig         | 2 +-
 configs/puma-rk3399_defconfig                 | 2 +-
 configs/px30-core-ctouch2-of10-px30_defconfig | 2 +-
 configs/px30-core-ctouch2-px30_defconfig      | 2 +-
 configs/px30-core-edimm2.2-px30_defconfig     | 2 +-
 configs/qnap-ts433-rk3568_defconfig           | 2 +-
 configs/quartz64-a-rk3566_defconfig           | 2 +-
 configs/quartz64-b-rk3566_defconfig           | 2 +-
 configs/quartzpro64-rk3588_defconfig          | 2 +-
 configs/radxa-cm3-io-rk3566_defconfig         | 2 +-
 configs/radxa-e25-rk3568_defconfig            | 2 +-
 configs/radxa-zero-3-rk3566_defconfig         | 2 +-
 configs/rk3399-generic-ddr3_defconfig         | 2 +-
 configs/roc-cc-rk3308_defconfig               | 2 +-
 configs/roc-cc-rk3328_defconfig               | 2 +-
 configs/roc-pc-mezzanine-rk3399_defconfig     | 2 +-
 configs/roc-pc-rk3399_defconfig               | 2 +-
 configs/rock-3a-rk3568_defconfig              | 2 +-
 configs/rock-3b-rk3568_defconfig              | 2 +-
 configs/rock-3c-rk3566_defconfig              | 2 +-
 configs/rock-4c-plus-rk3399_defconfig         | 2 +-
 configs/rock-4se-rk3399_defconfig             | 2 +-
 configs/rock-5-itx-rk3588_defconfig           | 2 +-
 configs/rock-5c-rk3588s_defconfig             | 2 +-
 configs/rock-pi-4-rk3399_defconfig            | 2 +-
 configs/rock-pi-4c-rk3399_defconfig           | 2 +-
 configs/rock-pi-e-rk3328_defconfig            | 2 +-
 configs/rock-pi-e-v3-rk3328_defconfig         | 2 +-
 configs/rock-pi-n10-rk3399pro_defconfig       | 2 +-
 configs/rock-pi-n8-rk3288_defconfig           | 2 +-
 configs/rock-pi-s-rk3308_defconfig            | 2 +-
 configs/rock-s0-rk3308_defconfig              | 2 +-
 configs/rock2_defconfig                       | 2 +-
 configs/rock5a-rk3588s_defconfig              | 2 +-
 configs/rock5b-rk3588_defconfig               | 2 +-
 configs/rock64-rk3328_defconfig               | 2 +-
 configs/rock960-rk3399_defconfig              | 2 +-
 configs/rock_defconfig                        | 2 +-
 configs/rockpro64-rk3399_defconfig            | 2 +-
 configs/sige7-rk3588_defconfig                | 2 +-
 configs/sonoff-ihost-rv1126_defconfig         | 2 +-
 configs/soquartz-blade-rk3566_defconfig       | 2 +-
 configs/soquartz-cm4-rk3566_defconfig         | 2 +-
 configs/soquartz-model-a-rk3566_defconfig     | 2 +-
 configs/tiger-rk3588_defconfig                | 2 +-
 configs/tinker-rk3288_defconfig               | 2 +-
 configs/tinker-s-rk3288_defconfig             | 2 +-
 configs/toybrick-rk3588_defconfig             | 2 +-
 configs/turing-rk1-rk3588_defconfig           | 2 +-
 configs/vyasa-rk3288_defconfig                | 2 +-
 125 files changed, 125 insertions(+), 124 deletions(-)
arch/arm/dts/rockchip-u-boot.dtsi +1 -0
index 0d59aad86bf..937d5a81742 100644
@@ -201,6 +201,7 @@
 	simple-bin {
 		filename = "u-boot-rockchip.bin";
 		pad-byte = <0xff>;
+		skip-at-start = <0x8000>;
 
 #ifndef CONFIG_VPL
 		mkimage {
configs/anbernic-rgxx3-rk3566_defconfig +1 -1
index 14c97b4c5bf..972d4c71b14 100644
@@ -28,7 +28,7 @@ CONFIG_BOARD_TYPES=y
 CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_BOARD_RNG_SEED=y
 CONFIG_SPL_MAX_SIZE=0x40000
-CONFIG_SPL_PAD_TO=0x7f8000
+CONFIG_SPL_PAD_TO=0x800000
 CONFIG_SPL_BOARD_INIT=y
 # CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
 CONFIG_SPL_POWER=y

[snip]

#52 lore raw

Re: [PATCH v2 30/35] rockchip: Set the skip-at-start property correctly

Hi Jonas,

Quoted 4 lines · Jonas Karlman

Hi Simon,

On 2025-02-09 22:14, Simon Glass wrote:

Quoted 8 lines
Quoted 5 lines

The rockchip image is written to the media at block 64, which is a 32K offset, so set the skip-at-start property to 0x8000

Update CONFIG_SPL_PAD_TO to point to the offset in the image, since Binman is dealing with the 'missing' 32K now.

This confuses me, to me the image is the output binary image. And the offset in the image is what SPL_PAD_TO already is referring to.

It is confusing, but there actually isn't any change in where things are placed in the image. All that is changing is that binman is handling it for us.

This depends on the binf series ("Honour the skip-at-start property more faithfully") of which I'm sending a new version.

Quoted 4 lines

The help for SPL_PAD_TO mention "Image offset to which the SPL should be padded before appending the SPL payload.".

Quoted 8 lines

I can be fine with changing it to payload location in storage, however do such mass change in a separate series and with a clear explanation why SPL_PAD_TO should mean the offset on storage and not offset in the output binary image written to storage.

With one patch that just add the skip-at-start prop and adjust to use <(CONFIG_SPL_PAD_TO + 0x8000)> for the offset prop. And put the mass change to defconfig in a separate patch.

But that would break bisectability, wouldn't it?

Quoted 3 lines

Another option could possible be to use SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR in a calculation and drop use of the SPL_PAD_TO symbol.

There are too many options and we should really just be using Binman. But this is a step in the right direction.

Quoted 4 lines

Else this blocks others from adding new boards, and/or will break them if a defconfig was missed. With a separate series adding a new board can just reference the smaller series.

OK, once the binf series is in, then this could go in separately?

Quoted 12 lines

Regards,
Jonas

Quoted 8 lines

---

Changes in v2:
- Move this patch to the end of the series
- Drop 0x8000 offset for SPI

[..]

Regards,
SImon

#53 lore raw

PATCH v2 31/35 vbe: Add a bootmeth driver for abrec

In reply to Simon Glass

Add a VBE-ABrec bootmeth so that the VBE state can be accessed.

---

Changes in v2:
- Add new patch with a bootmeth driver for abrec

 boot/vbe_abrec.c | 99 ++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 99 insertions(+)
boot/vbe_abrec.c +99 -0
index 6d0f622262d..8593082fd79 100644
@@ -8,6 +8,7 @@
 
 #define LOG_CATEGORY LOGC_BOOT
 
+#include <bootmeth.h>
 #include <dm.h>
 #include <memalign.h>
 #include <mmc.h>
@@ -81,3 +82,101 @@ int abrec_read_state(struct udevice *dev, struct abrec_state *state)
 
 	return 0;
 }
+
+static int vbe_abrec_get_state_desc(struct udevice *dev, char *buf,
+				    int maxsize)
+{
+	struct abrec_state state;
+	int ret;
+
+	ret = abrec_read_state(dev, &state);
+	if (ret)
+		return log_msg_ret("read", ret);
+
+	if (maxsize < 30)
+		return -ENOSPC;
+	snprintf(buf, maxsize, "Version: %s\nVernum: %x/%x", state.fw_version,
+		 state.fw_vernum >> FWVER_KEY_SHIFT,
+		 state.fw_vernum & FWVER_FW_MASK);
+
+	return 0;
+}
+
+static int vbe_abrec_read_bootflow(struct udevice *dev, struct bootflow *bflow)
+{
+	int ret;
+
+	if (CONFIG_IS_ENABLED(BOOTMETH_VBE_ABREC_FW)) {
+		if (vbe_phase() == VBE_PHASE_FIRMWARE) {
+			ret = abrec_read_bootflow_fw(dev, bflow);
+			if (ret)
+				return log_msg_ret("fw", ret);
+			return 0;
+		}
+	}
+
+	return -EINVAL;
+}
+
+static int vbe_abrec_read_file(struct udevice *dev, struct bootflow *bflow,
+			       const char *file_path, ulong addr,
+			       enum bootflow_img_t type, ulong *sizep)
+{
+	int ret;
+
+	if (vbe_phase() == VBE_PHASE_OS) {
+		ret = bootmeth_common_read_file(dev, bflow, file_path, addr,
+						type, sizep);
+		if (ret)
+			return log_msg_ret("os", ret);
+	}
+
+	/* To be implemented */
+	return -EINVAL;
+}
+
+static struct bootmeth_ops bootmeth_vbe_abrec_ops = {
+	.get_state_desc	= vbe_abrec_get_state_desc,
+	.read_bootflow	= vbe_abrec_read_bootflow,
+	.read_file	= vbe_abrec_read_file,
+};
+
+static int bootmeth_vbe_abrec_probe(struct udevice *dev)
+{
+	struct abrec_priv *priv = dev_get_priv(dev);
+	int ret;
+
+	ret = abrec_read_priv(dev_ofnode(dev), priv);
+	if (ret)
+		return log_msg_ret("abp", ret);
+
+	return 0;
+}
+
+static int bootmeth_vbe_abrec_bind(struct udevice *dev)
+{
+	struct bootmeth_uc_plat *plat = dev_get_uclass_plat(dev);
+
+	plat->desc = "VBE A/B/recovery";
+	plat->flags = BOOTMETHF_GLOBAL;
+
+	return 0;
+}
+
+#if CONFIG_IS_ENABLED(OF_REAL)
+static const struct udevice_id generic_simple_vbe_abrec_ids[] = {
+	{ .compatible = "fwupd,vbe-abrec" },
+	{ }
+};
+#endif
+
+U_BOOT_DRIVER(vbe_abrec) = {
+	.name	= "vbe_abrec",
+	.id	= UCLASS_BOOTMETH,
+	.of_match = of_match_ptr(generic_simple_vbe_abrec_ids),
+	.ops	= &bootmeth_vbe_abrec_ops,
+	.bind	= bootmeth_vbe_abrec_bind,
+	.probe	= bootmeth_vbe_abrec_probe,
+	.flags	= DM_FLAG_PRE_RELOC,
+	.priv_auto	= sizeof(struct abrec_priv),
+};
Signature · 1 line
2.43.0
#54 lore raw

PATCH v2 32/35 rockchip: Update binman image for new skip-at-start setup

In reply to Simon Glass

Now that the skip-at-start feature is properly used in Binman, drop the various workarounds in the image.

---

Changes in v2:
- Split out the fixes for skip-at-start into a new patch

 arch/arm/dts/rockchip-vpl-u-boot.dtsi | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)
arch/arm/dts/rockchip-vpl-u-boot.dtsi +3 -4
index 621161f6c86..71d7a98e5ac 100644
@@ -19,7 +19,6 @@
 			bootph-verify;
 			compatible = "fwupd,vbe-abrec";
 			storage = "mmc0";
-			skip-offset = <0x8000>;
 			area-start = <CONFIG_SPL_PAD_TO>;
 			area-size = <0x800000>;
 			state-offset = <(CONFIG_SPL_PAD_TO - 0x400)>;
@@ -77,7 +76,7 @@
 
 		vpl {
 			type = "fit";
-			offset = <(CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 0x200 + 0x8000)>;
+			offset = <(CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 0x200)>;
 			description = "FIT image for U-Boot TPL";
 			#address-cells = <1>;
 			fit,fdt-list = "of-list";
@@ -122,7 +121,7 @@
 # ifdef CONFIG_BOOTMETH_VBE_ABREC
 		vbe-a {
 			type = "section";
-			offset = <(CONFIG_SPL_PAD_TO + 0x8000)>;
+			offset = <CONFIG_SPL_PAD_TO>;
 			spl-a {
 				insert-template = <&spl_template>;
 				size = <0x100000>;
@@ -159,7 +158,7 @@
 # else /* CONFIG_BOOTMETH_VBE_SIMPLE */
 		vbe {
 			type = "fit";
-			offset = <(CONFIG_SPL_PAD_TO + 0x8000)>;
+			offset = <CONFIG_SPL_PAD_TO>;
 			insert-template = <&common_part>;
 		};
 # endif /* VBE method */
Signature · 1 line
2.43.0
#55 lore raw

PATCH v2 33/35 RFC: Revert "bloblist: Load the bloblist from the previous loader"

In reply to Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)
common/bloblist.c +19 -45
index e8acfc74331..7eda94ecdf9 100644
@@ -487,57 +487,37 @@ int bloblist_reloc(void *to, uint to_size)
 	return 0;
 }
 
-/*
- * Weak default function for getting bloblist from boot args.
- */
-int __weak xferlist_from_boot_arg(ulong __always_unused addr,
-				  ulong __always_unused size)
-{
-	return -ENOENT;
-}
-
 int bloblist_init(void)
 {
 	bool fixed = IS_ENABLED(CONFIG_BLOBLIST_FIXED);
 	int ret = -ENOENT;
-	ulong addr = 0, size;
-	/*
-	 * If U-Boot is not in the first phase, an existing bloblist must be
-	 * at a fixed address.
-	 */
-	bool from_addr = fixed && !xpl_is_first_phase();
-	/*
-	 * If U-Boot is in the first phase that an arch custom routine should
-	 * install the bloblist passed from previous loader to this fixed
+	ulong addr, size;
+	bool expected;
+
+	/**
+	 * We don't expect to find an existing bloblist in the first phase of
+	 * U-Boot that runs. Also we have no way to receive the address of an
+	 * allocated bloblist from a previous stage, so it must be at a fixed
 	 * address.
 	 */
-	bool from_boot_arg = fixed && xpl_is_first_phase();
-
+	expected = fixed && !xpl_is_first_phase();
 	if (xpl_prev_phase() == PHASE_TPL && !IS_ENABLED(CONFIG_TPL_BLOBLIST))
-		from_addr = false;
+		expected = false;
 	if (fixed)
 		addr = IF_ENABLED_INT(CONFIG_BLOBLIST_FIXED,
 				      CONFIG_BLOBLIST_ADDR);
 	size = CONFIG_BLOBLIST_SIZE;
-
-	if (from_boot_arg)
-		ret = xferlist_from_boot_arg(addr, size);
-	else if (from_addr)
+	if (expected) {
 		ret = bloblist_check(addr, size);
-
-	if (ret)
-		log_warning("Bloblist at %lx not found (err=%d)\n",
-			    addr, ret);
-	else
-		/* Get the real size */
-		size = gd->bloblist->total_size;
-
+		if (ret) {
+			log_warning("Expected bloblist at %lx not found (err=%d)\n",
+				    addr, ret);
+		} else {
+			/* Get the real size, if it is not what we expected */
+			size = gd->bloblist->total_size;
+		}
+	}
 	if (ret) {
-		/*
-		 * If we don't have a bloblist from a fixed address, or the one
-		 * in the fixed address is not valid. we must allocate the
-		 * memory for it now.
-		 */
 		if (CONFIG_IS_ENABLED(BLOBLIST_ALLOC)) {
 			void *ptr = memalign(BLOBLIST_ALIGN, size);
 
@@ -545,8 +525,7 @@ int bloblist_init(void)
 				return log_msg_ret("alloc", -ENOMEM);
 			addr = map_to_sysmem(ptr);
 		} else if (!fixed) {
-			return log_msg_ret("BLOBLIST_FIXED is not enabled",
-					   ret);
+			return log_msg_ret("!fixed", ret);
 		}
 		log_debug("Creating new bloblist size %lx at %lx\n", size,
 			  addr);
@@ -559,11 +538,6 @@ int bloblist_init(void)
 		return log_msg_ret("ini", ret);
 	gd->flags |= GD_FLG_BLOBLIST_READY;
 
-#ifdef DEBUG
-	bloblist_show_stats();
-	bloblist_show_list();
-#endif
-
 	return 0;
 }
 
include/bloblist.h +0 -10
index 1e1ca34aa92..5063ab66e4a 100644
@@ -482,14 +482,4 @@ static inline int bloblist_maybe_init(void)
  */
 int bloblist_check_reg_conv(ulong rfdt, ulong rzero, ulong rsig);
 
-/**
- * xferlist_from_boot_arg() - Get bloblist from the boot args and relocate it
- *			      to the specified address.
- *
- * @addr: Address for the bloblist
- * @size: Size of space reserved for the bloblist
- * Return: 0 if OK, else on error
- */
-int xferlist_from_boot_arg(ulong addr, ulong size);
-
 #endif /* __BLOBLIST_H */
Signature · 1 line
2.43.0
#56 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Quoted 18 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

Quoted 8 lines

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Signature · 1 line
Tom
#57 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Hi Tom,

Quoted 26 lines · Tom Rini
Quoted 23 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

Quoted 7 lines
Quoted 3 lines
 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

Regards,
Simon

#58 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini
Quoted 26 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)
Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 8 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

Signature · 1 line
Tom
#59 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Hi Tom,

Quoted 50 lines · Tom Rini
Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini
Quoted 26 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)
Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 6 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

Quoted 8 lines
Quoted 2 lines

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

- Simon

#60 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Hi Tom,

Quoted 60 lines · Simon Glass

Hi Tom,

Quoted 56 lines · Tom Rini
Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini
Quoted 26 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)
Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 8 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Quoted 6 lines
Quoted 2 lines

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

Also, I forgot to mention that U-Boot doesn't seem to support the firmware handoff protocol in SPL? If so, could you point me to the code?

Regards,
Simon

#61 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Quoted 66 lines · Simon Glass

Hi Tom,

Quoted 63 lines · Simon Glass

Hi Tom,

Quoted 58 lines · Tom Rini
Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini
Quoted 26 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)
Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 8 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

Quoted 7 lines
Quoted 3 lines

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

Also, I forgot to mention that U-Boot doesn't seem to support the firmware handoff protocol in SPL? If so, could you point me to the code?

Yes, you never implemented handoff between stages in U-Boot via register. That's not a use case for the platforms that don't use U-Boot for SPL.

Signature · 1 line
Tom
#62 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Hi Tom,

Quoted 72 lines · Tom Rini
Quoted 70 lines · Simon Glass

Hi Tom,

Quoted 66 lines · Simon Glass

Hi Tom,

Quoted 50 lines · Tom Rini
Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini
Quoted 26 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)
Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 6 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

Quoted 8 lines
Quoted 2 lines

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

Quoted 7 lines
Quoted 3 lines

Also, I forgot to mention that U-Boot doesn't seem to support the firmware handoff protocol in SPL? If so, could you point me to the code?

Yes, you never implemented handoff between stages in U-Boot via register. That's not a use case for the platforms that don't use U-Boot for SPL.

If you let me own bloblist, I'll own it, but for now I am staying away.

Regards,
Simon

#63 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Quoted 79 lines · Simon Glass

Hi Tom,

Quoted 76 lines · Tom Rini
Quoted 73 lines · Simon Glass

Hi Tom,

Quoted 60 lines · Simon Glass

Hi Tom,

Quoted 56 lines · Tom Rini
Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini
Quoted 26 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)
Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 8 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Quoted 6 lines
Quoted 2 lines

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

Also, I forgot to mention that U-Boot doesn't seem to support the firmware handoff protocol in SPL? If so, could you point me to the code?

Quoted 5 lines
Quoted 3 lines

Yes, you never implemented handoff between stages in U-Boot via register. That's not a use case for the platforms that don't use U-Boot for SPL.

If you let me own bloblist, I'll own it, but for now I am staying away.

Would you be working against mainline again, and not breaking standard passage (as it's been split off) ?

Signature · 1 line
Tom
#64 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Hi Tom,

Quoted 81 lines · Tom Rini
Quoted 79 lines · Simon Glass

Hi Tom,

Quoted 76 lines · Tom Rini
Quoted 73 lines · Simon Glass

Hi Tom,

Quoted 60 lines · Simon Glass

Hi Tom,

Quoted 56 lines · Tom Rini
Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini
Quoted 26 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)
Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 8 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Quoted 6 lines
Quoted 2 lines

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

Also, I forgot to mention that U-Boot doesn't seem to support the firmware handoff protocol in SPL? If so, could you point me to the code?

Quoted 8 lines
Quoted 5 lines
Quoted 3 lines

Yes, you never implemented handoff between stages in U-Boot via register. That's not a use case for the platforms that don't use U-Boot for SPL.

If you let me own bloblist, I'll own it, but for now I am staying away.

Would you be working against mainline again, and not breaking standard passage (as it's been split off) ?

Sure. The only reason I have my tree is because (I feel that) parts of U-Boot have become no-go for me. So if you'd like me to maintain bloblist again, I would be delighted to do so.

Steps I see:
- Get my boards working again
- Add standard passage from SPL->PPL
- Figure out what to do on x86 to also use standard passage

I'm not quite sure that BLOBLIST_FIXED can be removed, as it needs more thought. The phase that creates the bloblist initially needs to know where to put it.

Regards,
Simon

#65 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Quoted 93 lines · Simon Glass

Hi Tom,

Quoted 81 lines · Tom Rini
Quoted 79 lines · Simon Glass

Hi Tom,

Quoted 76 lines · Tom Rini
Quoted 73 lines · Simon Glass

Hi Tom,

Quoted 60 lines · Simon Glass

Hi Tom,

Quoted 56 lines · Tom Rini
Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini
Quoted 26 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)
Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 8 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Quoted 6 lines
Quoted 2 lines

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

Also, I forgot to mention that U-Boot doesn't seem to support the firmware handoff protocol in SPL? If so, could you point me to the code?

Quoted 8 lines
Quoted 5 lines
Quoted 3 lines

Yes, you never implemented handoff between stages in U-Boot via register. That's not a use case for the platforms that don't use U-Boot for SPL.

If you let me own bloblist, I'll own it, but for now I am staying away.

Would you be working against mainline again, and not breaking standard passage (as it's been split off) ?

Quoted 6 lines

Sure. The only reason I have my tree is because (I feel that) parts of U-Boot have become no-go for me. So if you'd like me to maintain bloblist again, I would be delighted to do so.

Steps I see:
- Get my boards working again

Already done. I'm waiting for Kever to pick up Jonas' small series that brings back output prior to that statement from DM.

Quoted 1 line

- Add standard passage from SPL->PPL

By who? PPL (and xPL) already reads standard passage via register.

Quoted 1 line

- Figure out what to do on x86 to also use standard passage

Standard passage, or bloblist?

Quoted 3 lines

I'm not quite sure that BLOBLIST_FIXED can be removed, as it needs more thought. The phase that creates the bloblist initially needs to know where to put it.

When a phase is running it already has to know what memory is available right now or not, and can allocate as much of a list as it needs now. Later phases can move/grow it.

Signature · 1 line
Tom
#66 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Quoted 112 lines · Tom Rini
Quoted 93 lines · Simon Glass

Hi Tom,

Quoted 81 lines · Tom Rini
Quoted 79 lines · Simon Glass

Hi Tom,

Quoted 76 lines · Tom Rini
Quoted 73 lines · Simon Glass

Hi Tom,

Quoted 60 lines · Simon Glass

Hi Tom,

Quoted 56 lines · Tom Rini
Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini
Quoted 26 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)
Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 8 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Quoted 6 lines
Quoted 2 lines

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

Also, I forgot to mention that U-Boot doesn't seem to support the firmware handoff protocol in SPL? If so, could you point me to the code?

Quoted 8 lines
Quoted 5 lines
Quoted 3 lines

Yes, you never implemented handoff between stages in U-Boot via register. That's not a use case for the platforms that don't use U-Boot for SPL.

If you let me own bloblist, I'll own it, but for now I am staying away.

Would you be working against mainline again, and not breaking standard passage (as it's been split off) ?

Quoted 6 lines

Sure. The only reason I have my tree is because (I feel that) parts of U-Boot have become no-go for me. So if you'd like me to maintain bloblist again, I would be delighted to do so.

Steps I see:
- Get my boards working again

Already done. I'm waiting for Kever to pick up Jonas' small series that brings back output prior to that statement from DM.

Quoted 1 line

- Add standard passage from SPL->PPL

By who? PPL (and xPL) already reads standard passage via register.

Quoted 1 line

- Figure out what to do on x86 to also use standard passage

Standard passage, or bloblist?

Quoted 7 lines
Quoted 3 lines

I'm not quite sure that BLOBLIST_FIXED can be removed, as it needs more thought. The phase that creates the bloblist initially needs to know where to put it.

When a phase is running it already has to know what memory is available right now or not, and can allocate as much of a list as it needs now. Later phases can move/grow it.

Actually, let me elaborate and then concede.

What I think the best design for BLOBLIST would be is:
- Uncouple "was I passed a bloblist" from "create a bloblist"
- Only allow passing bloblist via register(s).
- No bloblist contents can be globally mandatory until PPL.
- Platforms may declare something mandatory (ie very first phase shall init certain clocks and hand that off to next stage) if necessary.
- A bloblist *should* be dynamically allocated but that's not required.

I believe this solves problems such as:
- We don't need OF_BLOBLIST because if we were not passed a bloblist we don't go and create one at a possibly inaccessible location.
- With fixed locations discouraged we wouldn't be forcing ourselves to choose between limited on-chip RAM or DRAM for everything prior to PPL relocating it.

With all that, if we untie standard passage from bloblist (and maybe we want to revisit that in a year or two), bloblist can do what it likes so long as standard passage isn't broken. And with it being uncoupled, it should not get broken. I'll stop trying to convince you of a better design.

Signature · 1 line
Tom
#67 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Hi Tom,

Quoted 139 lines · Tom Rini
Quoted 112 lines · Tom Rini
Quoted 93 lines · Simon Glass

Hi Tom,

Quoted 81 lines · Tom Rini
Quoted 79 lines · Simon Glass

Hi Tom,

Quoted 76 lines · Tom Rini
Quoted 73 lines · Simon Glass

Hi Tom,

Quoted 60 lines · Simon Glass

Hi Tom,

Quoted 56 lines · Tom Rini
Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini
Quoted 26 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)
Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 8 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Quoted 6 lines
Quoted 2 lines

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

Also, I forgot to mention that U-Boot doesn't seem to support the firmware handoff protocol in SPL? If so, could you point me to the code?

Quoted 8 lines
Quoted 5 lines
Quoted 3 lines

Yes, you never implemented handoff between stages in U-Boot via register. That's not a use case for the platforms that don't use U-Boot for SPL.

If you let me own bloblist, I'll own it, but for now I am staying away.

Would you be working against mainline again, and not breaking standard passage (as it's been split off) ?

Quoted 6 lines

Sure. The only reason I have my tree is because (I feel that) parts of U-Boot have become no-go for me. So if you'd like me to maintain bloblist again, I would be delighted to do so.

Steps I see:
- Get my boards working again

Already done. I'm waiting for Kever to pick up Jonas' small series that brings back output prior to that statement from DM.

Quoted 1 line

- Add standard passage from SPL->PPL

By who? PPL (and xPL) already reads standard passage via register.

Quoted 1 line

- Figure out what to do on x86 to also use standard passage

Standard passage, or bloblist?

Quoted 7 lines
Quoted 3 lines

I'm not quite sure that BLOBLIST_FIXED can be removed, as it needs more thought. The phase that creates the bloblist initially needs to know where to put it.

When a phase is running it already has to know what memory is available right now or not, and can allocate as much of a list as it needs now. Later phases can move/grow it.

Actually, let me elaborate and then concede.

What I think the best design for BLOBLIST would be is:
- Uncouple "was I passed a bloblist" from "create a bloblist"
- Only allow passing bloblist via register(s).
- No bloblist contents can be globally mandatory until PPL.
- Platforms may declare something mandatory (ie very first phase shall init certain clocks and hand that off to next stage) if necessary.
- A bloblist *should* be dynamically allocated but that's not required.

I believe this solves problems such as:
- We don't need OF_BLOBLIST because if we were not passed a bloblist we don't go and create one at a possibly inaccessible location.
- With fixed locations discouraged we wouldn't be forcing ourselves to choose between limited on-chip RAM or DRAM for everything prior to PPL relocating it.

Quoted 5 lines

With all that, if we untie standard passage from bloblist (and maybe we want to revisit that in a year or two), bloblist can do what it likes so long as standard passage isn't broken. And with it being uncoupled, it should not get broken. I'll stop trying to convince you of a better design.

If you can convince people to let me act as maintainer (with the final say) for bloblist then I'm happy to do so and I can work towards the design above.

I think we have the same end point, but perhaps disagree on whether it all needs to be done at once. The only question I have is about the 'mandatory' stuff. I worry that this is an attempt to make it impossible for U-Boot to use its own devicetree, even as an option. So long as it isn't, fine.

My general issue with bloblist is that it has been broken for me for over a year and it just takes too much energy to get changes in. The OF_BLOBLIST thing was just the worst and I would rather not repeat it. I just looked at your tree and there is no OF_BLOBLIST.

Regards,
Simon

#68 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Quoted 158 lines · Simon Glass

Hi Tom,

Quoted 139 lines · Tom Rini
Quoted 112 lines · Tom Rini
Quoted 93 lines · Simon Glass

Hi Tom,

Quoted 81 lines · Tom Rini
Quoted 79 lines · Simon Glass

Hi Tom,

Quoted 76 lines · Tom Rini
Quoted 73 lines · Simon Glass

Hi Tom,

Quoted 60 lines · Simon Glass

Hi Tom,

Quoted 56 lines · Tom Rini
Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini
Quoted 26 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a
bloblist in the first phase where BLOBLIST is enabled. Subsequent
phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting
things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series,
a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

Signed-off-by: Simon Glass <[email protected]>
---

(no changes since v1)

common/bloblist.c | 64 ++++++++++++++--------------------------------
include/bloblist.h | 10 --------
2 files changed, 19 insertions(+), 55 deletions(-)

Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 8 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Quoted 6 lines
Quoted 2 lines

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

Also, I forgot to mention that U-Boot doesn't seem to support the firmware handoff protocol in SPL? If so, could you point me to the code?

Quoted 8 lines
Quoted 5 lines
Quoted 3 lines

Yes, you never implemented handoff between stages in U-Boot via register. That's not a use case for the platforms that don't use U-Boot for SPL.

If you let me own bloblist, I'll own it, but for now I am staying away.

Would you be working against mainline again, and not breaking standard passage (as it's been split off) ?

Quoted 6 lines

Sure. The only reason I have my tree is because (I feel that) parts of U-Boot have become no-go for me. So if you'd like me to maintain bloblist again, I would be delighted to do so.

Steps I see:
- Get my boards working again

Already done. I'm waiting for Kever to pick up Jonas' small series that brings back output prior to that statement from DM.

Quoted 1 line

- Add standard passage from SPL->PPL

By who? PPL (and xPL) already reads standard passage via register.

Quoted 1 line

- Figure out what to do on x86 to also use standard passage

Standard passage, or bloblist?

Quoted 7 lines
Quoted 3 lines

I'm not quite sure that BLOBLIST_FIXED can be removed, as it needs more thought. The phase that creates the bloblist initially needs to know where to put it.

When a phase is running it already has to know what memory is available right now or not, and can allocate as much of a list as it needs now. Later phases can move/grow it.

Actually, let me elaborate and then concede.

What I think the best design for BLOBLIST would be is:
- Uncouple "was I passed a bloblist" from "create a bloblist"
- Only allow passing bloblist via register(s).
- No bloblist contents can be globally mandatory until PPL.
- Platforms may declare something mandatory (ie very first phase shall init certain clocks and hand that off to next stage) if necessary.
- A bloblist *should* be dynamically allocated but that's not required.

I believe this solves problems such as:
- We don't need OF_BLOBLIST because if we were not passed a bloblist we don't go and create one at a possibly inaccessible location.
- With fixed locations discouraged we wouldn't be forcing ourselves to choose between limited on-chip RAM or DRAM for everything prior to PPL relocating it.

Quoted 5 lines

With all that, if we untie standard passage from bloblist (and maybe we want to revisit that in a year or two), bloblist can do what it likes so long as standard passage isn't broken. And with it being uncoupled, it should not get broken. I'll stop trying to convince you of a better design.

If you can convince people to let me act as maintainer (with the final say) for bloblist then I'm happy to do so and I can work towards the design above.

I think we have the same end point, but perhaps disagree on whether it all needs to be done at once. The only question I have is about the 'mandatory' stuff. I worry that this is an attempt to make it impossible for U-Boot to use its own devicetree, even as an option. So long as it isn't, fine.

Quoted 4 lines

My general issue with bloblist is that it has been broken for me for over a year and it just takes too much energy to get changes in. The OF_BLOBLIST thing was just the worst and I would rather not repeat it. I just looked at your tree and there is no OF_BLOBLIST.

If you're willing to let "standard passage" alone, I'll let you do whatever you like with "bloblist". I too am tired of re-hashing everything about OF_BLOBLIST.

Signature · 1 line
Tom
#69 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Hi Tom,

Quoted 160 lines · Tom Rini
Quoted 158 lines · Simon Glass

Hi Tom,

Quoted 139 lines · Tom Rini
Quoted 112 lines · Tom Rini
Quoted 93 lines · Simon Glass

Hi Tom,

Quoted 81 lines · Tom Rini
Quoted 79 lines · Simon Glass

Hi Tom,

Quoted 76 lines · Tom Rini
Quoted 73 lines · Simon Glass

Hi Tom,

Quoted 60 lines · Simon Glass

Hi Tom,

Quoted 56 lines · Tom Rini
Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini

On Sun, Feb 09, 2025 at 02:14:54PM -0700, Simon Glass wrote:

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a
bloblist in the first phase where BLOBLIST is enabled. Subsequent
phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting
things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series,
a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

Signed-off-by: Simon Glass <[email protected]>
---

(no changes since v1)

common/bloblist.c | 64 ++++++++++++++--------------------------------
include/bloblist.h | 10 --------
2 files changed, 19 insertions(+), 55 deletions(-)

Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of
your downstream fork you should start from that and stop posting it,
that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 8 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Quoted 6 lines
Quoted 2 lines

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

Also, I forgot to mention that U-Boot doesn't seem to support the firmware handoff protocol in SPL? If so, could you point me to the code?

Quoted 8 lines
Quoted 5 lines
Quoted 3 lines

Yes, you never implemented handoff between stages in U-Boot via register. That's not a use case for the platforms that don't use U-Boot for SPL.

If you let me own bloblist, I'll own it, but for now I am staying away.

Would you be working against mainline again, and not breaking standard passage (as it's been split off) ?

Quoted 6 lines

Sure. The only reason I have my tree is because (I feel that) parts of U-Boot have become no-go for me. So if you'd like me to maintain bloblist again, I would be delighted to do so.

Steps I see:
- Get my boards working again

Already done. I'm waiting for Kever to pick up Jonas' small series that brings back output prior to that statement from DM.

Quoted 1 line

- Add standard passage from SPL->PPL

By who? PPL (and xPL) already reads standard passage via register.

Quoted 1 line

- Figure out what to do on x86 to also use standard passage

Standard passage, or bloblist?

Quoted 7 lines
Quoted 3 lines

I'm not quite sure that BLOBLIST_FIXED can be removed, as it needs more thought. The phase that creates the bloblist initially needs to know where to put it.

When a phase is running it already has to know what memory is available right now or not, and can allocate as much of a list as it needs now. Later phases can move/grow it.

Actually, let me elaborate and then concede.

What I think the best design for BLOBLIST would be is:
- Uncouple "was I passed a bloblist" from "create a bloblist"
- Only allow passing bloblist via register(s).
- No bloblist contents can be globally mandatory until PPL.
- Platforms may declare something mandatory (ie very first phase shall init certain clocks and hand that off to next stage) if necessary.
- A bloblist *should* be dynamically allocated but that's not required.

I believe this solves problems such as:
- We don't need OF_BLOBLIST because if we were not passed a bloblist we don't go and create one at a possibly inaccessible location.
- With fixed locations discouraged we wouldn't be forcing ourselves to choose between limited on-chip RAM or DRAM for everything prior to PPL relocating it.

Quoted 5 lines

With all that, if we untie standard passage from bloblist (and maybe we want to revisit that in a year or two), bloblist can do what it likes so long as standard passage isn't broken. And with it being uncoupled, it should not get broken. I'll stop trying to convince you of a better design.

If you can convince people to let me act as maintainer (with the final say) for bloblist then I'm happy to do so and I can work towards the design above.

I think we have the same end point, but perhaps disagree on whether it all needs to be done at once. The only question I have is about the 'mandatory' stuff. I worry that this is an attempt to make it impossible for U-Boot to use its own devicetree, even as an option. So long as it isn't, fine.

Quoted 8 lines
Quoted 4 lines

My general issue with bloblist is that it has been broken for me for over a year and it just takes too much energy to get changes in. The OF_BLOBLIST thing was just the worst and I would rather not repeat it. I just looked at your tree and there is no OF_BLOBLIST.

If you're willing to let "standard passage" alone, I'll let you do whatever you like with "bloblist". I too am tired of re-hashing everything about OF_BLOBLIST.

That's fine, yes I will make sure standard passage stays working. If you could find your way to allowing OF_BLOBLIST I could do that too.

Regards,
Simon

#70 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Quoted 168 lines · Simon Glass

Hi Tom,

Quoted 165 lines · Tom Rini
Quoted 162 lines · Simon Glass

Hi Tom,

Quoted 139 lines · Tom Rini
Quoted 112 lines · Tom Rini
Quoted 93 lines · Simon Glass

Hi Tom,

Quoted 81 lines · Tom Rini
Quoted 79 lines · Simon Glass

Hi Tom,

Quoted 76 lines · Tom Rini
Quoted 73 lines · Simon Glass

Hi Tom,

Quoted 60 lines · Simon Glass

Hi Tom,

Quoted 56 lines · Tom Rini
Quoted 38 lines · Simon Glass

Hi Tom,

On Mon, 10 Feb 2025 at 07:33, Tom Rini <[email protected]> wrote:

On Sun, Feb 09, 2025 at 02:14:54PM -0700, Simon Glass wrote:

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a
bloblist in the first phase where BLOBLIST is enabled. Subsequent
phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting
things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series,
a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

Signed-off-by: Simon Glass <[email protected]>
---

(no changes since v1)

common/bloblist.c | 64 ++++++++++++++--------------------------------
include/bloblist.h | 10 --------
2 files changed, 19 insertions(+), 55 deletions(-)

We aren't reverting this change so if you plan to move this series out of
your downstream fork you should start from that and stop posting it,
that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 8 lines

My goal with this series is to have something that actually boots on a
real board, so the bloblist changes are needed for that, particularly
as the 'vbe' board in the lab tests this on the hardware. I
deliberately put these two patches at the end of the series so you can
ignore them if you'd like.

But for now, as I understand it, there are no users of standard
passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Quoted 6 lines
Quoted 2 lines

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

Also, I forgot to mention that U-Boot doesn't seem to support the firmware handoff protocol in SPL? If so, could you point me to the code?

Quoted 8 lines
Quoted 5 lines
Quoted 3 lines

Yes, you never implemented handoff between stages in U-Boot via register. That's not a use case for the platforms that don't use U-Boot for SPL.

If you let me own bloblist, I'll own it, but for now I am staying away.

Would you be working against mainline again, and not breaking standard passage (as it's been split off) ?

Quoted 6 lines

Sure. The only reason I have my tree is because (I feel that) parts of U-Boot have become no-go for me. So if you'd like me to maintain bloblist again, I would be delighted to do so.

Steps I see:
- Get my boards working again

Already done. I'm waiting for Kever to pick up Jonas' small series that brings back output prior to that statement from DM.

Quoted 1 line

- Add standard passage from SPL->PPL

By who? PPL (and xPL) already reads standard passage via register.

Quoted 1 line

- Figure out what to do on x86 to also use standard passage

Standard passage, or bloblist?

Quoted 7 lines
Quoted 3 lines

I'm not quite sure that BLOBLIST_FIXED can be removed, as it needs more thought. The phase that creates the bloblist initially needs to know where to put it.

When a phase is running it already has to know what memory is available right now or not, and can allocate as much of a list as it needs now. Later phases can move/grow it.

Actually, let me elaborate and then concede.

What I think the best design for BLOBLIST would be is:
- Uncouple "was I passed a bloblist" from "create a bloblist"
- Only allow passing bloblist via register(s).
- No bloblist contents can be globally mandatory until PPL.
- Platforms may declare something mandatory (ie very first phase shall init certain clocks and hand that off to next stage) if necessary.
- A bloblist *should* be dynamically allocated but that's not required.

I believe this solves problems such as:
- We don't need OF_BLOBLIST because if we were not passed a bloblist we don't go and create one at a possibly inaccessible location.
- With fixed locations discouraged we wouldn't be forcing ourselves to choose between limited on-chip RAM or DRAM for everything prior to PPL relocating it.

Quoted 5 lines

With all that, if we untie standard passage from bloblist (and maybe we want to revisit that in a year or two), bloblist can do what it likes so long as standard passage isn't broken. And with it being uncoupled, it should not get broken. I'll stop trying to convince you of a better design.

If you can convince people to let me act as maintainer (with the final say) for bloblist then I'm happy to do so and I can work towards the design above.

I think we have the same end point, but perhaps disagree on whether it all needs to be done at once. The only question I have is about the 'mandatory' stuff. I worry that this is an attempt to make it impossible for U-Boot to use its own devicetree, even as an option. So long as it isn't, fine.

My general issue with bloblist is that it has been broken for me for over a year and it just takes too much energy to get changes in. The OF_BLOBLIST thing was just the worst and I would rather not repeat it. I just looked at your tree and there is no OF_BLOBLIST.

Quoted 6 lines
Quoted 3 lines

If you're willing to let "standard passage" alone, I'll let you do whatever you like with "bloblist". I too am tired of re-hashing everything about OF_BLOBLIST.

That's fine, yes I will make sure standard passage stays working. If you could find your way to allowing OF_BLOBLIST I could do that too.

Part of splitting "bloblist" off from "standard passage" and outlining what I think would be a better "bloblist" design is that sure, we don't need OF_BLOBLIST except for when we say the bloblist exist in a fixed address in a point in memory that may not be available and we neither safely probe nor separate "check" from "create" but, fine, have OF_BLOBLIST.

I'm putting Raymond's series to split the two through CI today, for -next, so you can start on top of that later today or tomorrow.

Signature · 1 line
Tom
#71 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

In reply to Tom Rini

Hi Tom,

Quoted 99 lines · Tom Rini
Quoted 97 lines · Simon Glass

Hi Tom,

Quoted 81 lines · Tom Rini
Quoted 79 lines · Simon Glass

Hi Tom,

Quoted 76 lines · Tom Rini
Quoted 73 lines · Simon Glass

Hi Tom,

Quoted 60 lines · Simon Glass

Hi Tom,

Quoted 56 lines · Tom Rini
Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini
Quoted 26 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)
Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 8 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Quoted 6 lines
Quoted 2 lines

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

Also, I forgot to mention that U-Boot doesn't seem to support the firmware handoff protocol in SPL? If so, could you point me to the code?

Quoted 8 lines
Quoted 5 lines
Quoted 3 lines

Yes, you never implemented handoff between stages in U-Boot via register. That's not a use case for the platforms that don't use U-Boot for SPL.

If you let me own bloblist, I'll own it, but for now I am staying away.

Would you be working against mainline again, and not breaking standard passage (as it's been split off) ?

Sure. The only reason I have my tree is because (I feel that) parts of U-Boot have become no-go for me. So if you'd like me to maintain bloblist again, I would be delighted to do so.

Quoted 5 lines
Quoted 2 lines

Steps I see:
- Get my boards working again

Already done. I'm waiting for Kever to pick up Jonas' small series that brings back output prior to that statement from DM.

OK good.

Quoted 4 lines
Quoted 2 lines

- Add standard passage from SPL->PPL

By who? PPL (and xPL) already reads standard passage via register.

I mean implement it in SPL, so it can create the info and pass it to PPL.

Quoted 4 lines
Quoted 2 lines

- Figure out what to do on x86 to also use standard passage

Standard passage, or bloblist?

Well, bloblist today, but I hope we can come up with a standard passage for x86 too.

Quoted 8 lines
Quoted 4 lines

I'm not quite sure that BLOBLIST_FIXED can be removed, as it needs more thought. The phase that creates the bloblist initially needs to know where to put it.

When a phase is running it already has to know what memory is available right now or not, and can allocate as much of a list as it needs now. Later phases can move/grow it.

So you mean xPL should use malloc() / simple_malloc() rather than a fixed address? Or are you suggesting doing something in board_init_f_alloc_reserve()?

Regards,
Simon

#72 lore raw

Re: [PATCH v2 33/35] RFC: Revert "bloblist: Load the bloblist from the previous loader"

Quoted 118 lines · Simon Glass

Hi Tom,

Quoted 99 lines · Tom Rini
Quoted 97 lines · Simon Glass

Hi Tom,

Quoted 81 lines · Tom Rini
Quoted 79 lines · Simon Glass

Hi Tom,

Quoted 76 lines · Tom Rini
Quoted 73 lines · Simon Glass

Hi Tom,

Quoted 60 lines · Simon Glass

Hi Tom,

Quoted 56 lines · Tom Rini
Quoted 33 lines · Simon Glass

Hi Tom,

Quoted 30 lines · Tom Rini
Quoted 26 lines · Simon Glass

The logic of this has become too confusing.

The primary issue with the patch is that U-Boot needs to set up a bloblist in the first phase where BLOBLIST is enabled. Subsequent phases can then use that bloblist.

But the first phase of U-Boot cannot assume that one exists.

Reverting this commit seems like a better starting point for getting things working for all use-cases.

Note: The work to tidy this up is apparently underway. For this series, a revert is the easiest path.

This reverts commit 66131310d8ff1ba228f989b41bd8812f43be41c3.

https://lore.kernel.org/u-boot/CAPnjgZ3hMHtiH=f5ZKXNniOfV_-vFryq1Gn7QZ5hKU8Wjo8igw@mail.gmail.com/

---

(no changes since v1)

 common/bloblist.c  | 64 ++++++++++++++--------------------------------
 include/bloblist.h | 10 --------
 2 files changed, 19 insertions(+), 55 deletions(-)
Quoted 5 lines
Quoted 3 lines

We aren't reverting this change so if you plan to move this series out of your downstream fork you should start from that and stop posting it, that just leads to confusion.

Who is 'we', and start from what?

We, being the community, in here, the community mainline U-Boot project tree.

Quoted 8 lines

My goal with this series is to have something that actually boots on a real board, so the bloblist changes are needed for that, particularly as the 'vbe' board in the lab tests this on the hardware. I deliberately put these two patches at the end of the series so you can ignore them if you'd like.

But for now, as I understand it, there are no users of standard passage in tree, so actually it would be fine to apply them.

And you can ignore all the feedback you like for your downstream fork, sure.

Quoted 6 lines
Quoted 2 lines

Part of the feedback in this series already was "Yes, we can clean this up a bit more if bloblist will do its own thing instead".

So I see that Raymond's patch is a significant rewrite of what is there today, with multiple aims and changes. I would rather add my revert and start from a cleaner place.

Also, I forgot to mention that U-Boot doesn't seem to support the firmware handoff protocol in SPL? If so, could you point me to the code?

Quoted 8 lines
Quoted 5 lines
Quoted 3 lines

Yes, you never implemented handoff between stages in U-Boot via register. That's not a use case for the platforms that don't use U-Boot for SPL.

If you let me own bloblist, I'll own it, but for now I am staying away.

Would you be working against mainline again, and not breaking standard passage (as it's been split off) ?

Sure. The only reason I have my tree is because (I feel that) parts of U-Boot have become no-go for me. So if you'd like me to maintain bloblist again, I would be delighted to do so.

Quoted 5 lines
Quoted 2 lines

Steps I see:
- Get my boards working again

Already done. I'm waiting for Kever to pick up Jonas' small series that brings back output prior to that statement from DM.

OK good.

Quoted 4 lines
Quoted 2 lines

- Add standard passage from SPL->PPL

By who? PPL (and xPL) already reads standard passage via register.

I mean implement it in SPL, so it can create the info and pass it to PPL.

Quoted 1 line
Quoted 6 lines
Quoted 3 lines
Quoted 1 line

- Figure out what to do on x86 to also use standard passage

Standard passage, or bloblist?

Well, bloblist today, but I hope we can come up with a standard passage for x86 too.

My problem is "standard passage" has a meaning now, so it would be confusing to call "standard passage" one thing for arm and another for x86.

Quoted 11 lines
Quoted 7 lines
Quoted 3 lines

I'm not quite sure that BLOBLIST_FIXED can be removed, as it needs more thought. The phase that creates the bloblist initially needs to know where to put it.

When a phase is running it already has to know what memory is available right now or not, and can allocate as much of a list as it needs now. Later phases can move/grow it.

So you mean xPL should use malloc() / simple_malloc() rather than a fixed address? Or are you suggesting doing something in board_init_f_alloc_reserve()?

My high level point is that a phase must already know what memory it can and cannot touch, at run time.

Signature · 1 line
Tom
#73 lore raw

PATCH v2 34/35 rockchip: Relocate bloblist at the end of the SPL phase

In reply to Simon Glass

Where the bloblist is located in internal memory and TF-A's BL31 blob removes access to this memory, the best option seems to be to relocate the bloblist just before running TF-A.

Do this at the end of SPL.

---

Changes in v2:
- Move this logic into board-specific code

 arch/arm/mach-rockchip/spl.c | 14 ++++++++++++++
 1 file changed, 14 insertions(+)
arch/arm/mach-rockchip/spl.c +14 -0
index 305373a161c..64f056c27e9 100644
@@ -3,6 +3,7 @@
  * (C) Copyright 2019 Rockchip Electronics Co., Ltd
  */
 
+#include <bloblist.h>
 #include <cpu_func.h>
 #include <debug_uart.h>
 #include <dm.h>
@@ -133,6 +134,19 @@ void board_init_f(ulong dummy)
 
 void spl_board_prepare_for_boot(void)
 {
+	/*
+	 * On RK3399, TF-A is executed after SPL and before U-Boot. It removes
+	 * our access to the IRAM. So move the bloblist to RAM.
+	 */
+	if (xpl_phase() == PHASE_SPL && IS_ENABLED(CONFIG_VPL)) {
+		ulong addr = CONFIG_IF_ENABLED_INT(BLOBLIST_RELOC,
+						   BLOBLIST_RELOC_ADDR);
+
+		log_debug("Relocating bloblist %p to %lx\n", gd_bloblist(),
+			  addr);
+		bloblist_reloc(map_sysmem(addr, 0), bloblist_get_total_size());
+	}
+
 	if (!IS_ENABLED(CONFIG_ARM64) || CONFIG_IS_ENABLED(SYS_DCACHE_OFF))
 		return;
 
Signature · 1 line
2.43.0
#74 lore raw

PATCH v2 35/35 bloblist: Allow using a different bloblist address

In reply to Simon Glass

Where the bloblist is located in internal memory and TF-A's BL31 blob removes access to this memory, the best option seems to be to relocate the bloblist just before running TF-A.

We can do the relocation in board-specific code, but need an option to pick up the correct address within U-Boot proper.

---

Changes in v2:
- Move the actual relocation code to a previous board-specific patch

 common/Kconfig    | 20 ++++++++++++++++++++
 common/bloblist.c | 15 ++++++++++++++-
 2 files changed, 34 insertions(+), 1 deletion(-)
common/Kconfig +20 -0
index 0e8c44f3f74..962e7fd76eb 100644
@@ -1125,6 +1125,26 @@ config SPL_BLOBLIST_ALLOC
 
 endchoice
 
+config SPL_BLOBLIST_RELOC
+	bool "Relocate the bloblist before existing SPL"
+	depends on BLOBLIST_FIXED
+	help
+	  Some platforms locate the bloblist in SRAM in SPL. In some cases,
+	  the TF-A BL31 blob removes access to SRAM, e.g. with Rockchip RK3399.
+
+	  Enable this option to make U-Boot copy the bloblist from SRAM to SDRAM
+	  before leaving SPL.
+
+config SPL_BLOBLIST_RELOC_ADDR
+	hex "Relocate the bloblist before existing SPL"
+	depends on SPL_BLOBLIST_RELOC
+	default BLOBLIST_ADDR
+	help
+	  Sets the address to which the bloblist is relocated at the end of SPL.
+	  U-Boot proper uses this address when it starts up. Note that U-Boot
+	  always relocates the bloblist again as part of its own relocation
+	  process.
+
 endif # SPL_BLOBLIST
 
 if TPL_BLOBLIST
common/bloblist.c +14 -1
index 7eda94ecdf9..60c23d604b6 100644
@@ -503,9 +503,22 @@ int bloblist_init(void)
 	expected = fixed && !xpl_is_first_phase();
 	if (xpl_prev_phase() == PHASE_TPL && !IS_ENABLED(CONFIG_TPL_BLOBLIST))
 		expected = false;
-	if (fixed)
+	if (fixed) {
 		addr = IF_ENABLED_INT(CONFIG_BLOBLIST_FIXED,
 				      CONFIG_BLOBLIST_ADDR);
+
+		if (xpl_phase() == PHASE_BOARD_F &&
+		    IS_ENABLED(CONFIG_SPL_BLOBLIST_RELOC)) {
+			ulong addr = IF_ENABLED_INT(CONFIG_SPL_BLOBLIST_RELOC,
+					    CONFIG_SPL_BLOBLIST_RELOC_ADDR);
+
+			log_debug("Using bloblist at %lx\n", addr);
+			bloblist_reloc(map_sysmem(addr, 0),
+				       bloblist_get_total_size());
+		}
+		log_debug("bloblist addr=%lx\n", addr);
+	}
+
 	size = CONFIG_BLOBLIST_SIZE;
 	if (expected) {
 		ret = bloblist_check(addr, size);
Signature · 1 line
2.43.0
#75 lore raw

Re: [PATCH v2 35/35] bloblist: Allow using a different bloblist address

Quoted 8 lines · Simon Glass

Where the bloblist is located in internal memory and TF-A's BL31 blob removes access to this memory, the best option seems to be to relocate the bloblist just before running TF-A.

We can do the relocation in board-specific code, but need an option to pick up the correct address within U-Boot proper.

Quoted 8 lines

---

Changes in v2:
- Move the actual relocation code to a previous board-specific patch

 common/Kconfig    | 20 ++++++++++++++++++++
 common/bloblist.c | 15 ++++++++++++++-
 2 files changed, 34 insertions(+), 1 deletion(-)

I'm going to NAK this whole concept. The whole nightmare thread about these platforms comes from using a fixed address. We need to pass in a bloblist or see that one is not passed to us, via register. And then use that mechanism to pass the bloblist to the next phase. When we don't have a bloblist passed to us, we allocate one, and not at a fixed location.

Signature · 1 line
Tom
#76 lore raw

Re: [PATCH v2 35/35] bloblist: Allow using a different bloblist address

Hi Tom,

Quoted 20 lines · Tom Rini
Quoted 8 lines · Simon Glass

Where the bloblist is located in internal memory and TF-A's BL31 blob removes access to this memory, the best option seems to be to relocate the bloblist just before running TF-A.

We can do the relocation in board-specific code, but need an option to pick up the correct address within U-Boot proper.

Quoted 8 lines

---

Changes in v2:
- Move the actual relocation code to a previous board-specific patch

 common/Kconfig    | 20 ++++++++++++++++++++
 common/bloblist.c | 15 ++++++++++++++-
 2 files changed, 34 insertions(+), 1 deletion(-)
Quoted 6 lines

I'm going to NAK this whole concept. The whole nightmare thread about these platforms comes from using a fixed address. We need to pass in a bloblist or see that one is not passed to us, via register. And then use that mechanism to pass the bloblist to the next phase. When we don't have a bloblist passed to us, we allocate one, and not at a fixed location.

Well I understand that Linaro may be doing some work to head in that direction.

The 'piror-stage' stuff is what has made this all too hard and confusing. We should think of things from a U-Boot perspective and make that work. The new case can be handled by standard passage, along the lines that Raymond suggested, i.e. just checking for it first.

For x86 we don't need this path as there is no bloblist in TPL, i.e. it can be placed in DRAM from the start.

Regards,
Simon

#77 lore raw

Re: [PATCH v2 35/35] bloblist: Allow using a different bloblist address

Quoted 30 lines · Simon Glass

Hi Tom,

Quoted 20 lines · Tom Rini
Quoted 8 lines · Simon Glass

Where the bloblist is located in internal memory and TF-A's BL31 blob removes access to this memory, the best option seems to be to relocate the bloblist just before running TF-A.

We can do the relocation in board-specific code, but need an option to pick up the correct address within U-Boot proper.

Quoted 8 lines

---

Changes in v2:
- Move the actual relocation code to a previous board-specific patch

 common/Kconfig    | 20 ++++++++++++++++++++
 common/bloblist.c | 15 ++++++++++++++-
 2 files changed, 34 insertions(+), 1 deletion(-)
Quoted 6 lines

I'm going to NAK this whole concept. The whole nightmare thread about these platforms comes from using a fixed address. We need to pass in a bloblist or see that one is not passed to us, via register. And then use that mechanism to pass the bloblist to the next phase. When we don't have a bloblist passed to us, we allocate one, and not at a fixed location.

Quoted 2 lines

Well I understand that Linaro may be doing some work to head in that direction.

Are they? I don't know. I know Raymond was doing some clean up based on the idea of treating bloblist and standard passage as two separate things. Which I think is a terrible idea, despite suggesting it. But I think it's also the only way to make progress now that you've decided you can't work with them anymore.

Quoted 7 lines

The 'piror-stage' stuff is what has made this all too hard and confusing. We should think of things from a U-Boot perspective and make that work. The new case can be handled by standard passage, along the lines that Raymond suggested, i.e. just checking for it first.

For x86 we don't need this path as there is no bloblist in TPL, i.e. it can be placed in DRAM from the start.

A fixed address is a bad API for the U-Boot case and is what makes this all so confusing. And no, we can't put it in DRAM on x86 either, that's what had coral broke until I put it back in CAR.

Please explain why a fixed address is a better API than passing a known valid location via register, for the U-Boot case. I don't like it because it means that we cannot always safely check if it exists.

Signature · 1 line
Tom
#78 lore raw

Re: [PATCH v2 35/35] bloblist: Allow using a different bloblist address

Hi Tom,

Quoted 32 lines · Tom Rini
Quoted 30 lines · Simon Glass

Hi Tom,

Quoted 26 lines · Tom Rini
Quoted 8 lines · Simon Glass

Where the bloblist is located in internal memory and TF-A's BL31 blob removes access to this memory, the best option seems to be to relocate the bloblist just before running TF-A.

We can do the relocation in board-specific code, but need an option to pick up the correct address within U-Boot proper.

Quoted 8 lines

---

Changes in v2:
- Move the actual relocation code to a previous board-specific patch

 common/Kconfig    | 20 ++++++++++++++++++++
 common/bloblist.c | 15 ++++++++++++++-
 2 files changed, 34 insertions(+), 1 deletion(-)

I'm going to NAK this whole concept. The whole nightmare thread about these platforms comes from using a fixed address. We need to pass in a bloblist or see that one is not passed to us, via register. And then use that mechanism to pass the bloblist to the next phase. When we don't have a bloblist passed to us, we allocate one, and not at a fixed location.

Quoted 8 lines
Quoted 2 lines

Well I understand that Linaro may be doing some work to head in that direction.

Are they? I don't know. I know Raymond was doing some clean up based on the idea of treating bloblist and standard passage as two separate things. Which I think is a terrible idea, despite suggesting it. But I think it's also the only way to make progress now that you've decided you can't work with them anymore.

Can't work with who? Linaro? If you don't allow me to create patches for bloblist within your tree, what am I to do?

Quoted 13 lines
Quoted 8 lines

The 'piror-stage' stuff is what has made this all too hard and confusing. We should think of things from a U-Boot perspective and make that work. The new case can be handled by standard passage, along the lines that Raymond suggested, i.e. just checking for it first.

For x86 we don't need this path as there is no bloblist in TPL, i.e. it can be placed in DRAM from the start.

A fixed address is a bad API for the U-Boot case and is what makes this all so confusing. And no, we can't put it in DRAM on x86 either, that's what had coral broke until I put it back in CAR.

Quoted 6 lines

Please explain why a fixed address is a better API than passing a known valid location via register, for the U-Boot case. I don't like it because it means that we cannot always safely check if it exists.

--
Tom

Yes I would rather pass the location via register using standard passage, at least on ARM, where we have a suitable protocol. For now this is the only way for me to provide a series where VBE actually works in the lab.

Regards,
Simon

#79 lore raw

Re: [PATCH v2 35/35] bloblist: Allow using a different bloblist address

Quoted 64 lines · Simon Glass

Hi Tom,

Quoted 32 lines · Tom Rini
Quoted 30 lines · Simon Glass

Hi Tom,

Quoted 26 lines · Tom Rini
Quoted 8 lines · Simon Glass

Where the bloblist is located in internal memory and TF-A's BL31 blob removes access to this memory, the best option seems to be to relocate the bloblist just before running TF-A.

We can do the relocation in board-specific code, but need an option to pick up the correct address within U-Boot proper.

Quoted 8 lines

---

Changes in v2:
- Move the actual relocation code to a previous board-specific patch

 common/Kconfig    | 20 ++++++++++++++++++++
 common/bloblist.c | 15 ++++++++++++++-
 2 files changed, 34 insertions(+), 1 deletion(-)

I'm going to NAK this whole concept. The whole nightmare thread about these platforms comes from using a fixed address. We need to pass in a bloblist or see that one is not passed to us, via register. And then use that mechanism to pass the bloblist to the next phase. When we don't have a bloblist passed to us, we allocate one, and not at a fixed location.

Quoted 8 lines
Quoted 2 lines

Well I understand that Linaro may be doing some work to head in that direction.

Are they? I don't know. I know Raymond was doing some clean up based on the idea of treating bloblist and standard passage as two separate things. Which I think is a terrible idea, despite suggesting it. But I think it's also the only way to make progress now that you've decided you can't work with them anymore.

Can't work with who? Linaro? If you don't allow me to create patches for bloblist within your tree, what am I to do?

Quoted 17 lines
Quoted 8 lines

The 'piror-stage' stuff is what has made this all too hard and confusing. We should think of things from a U-Boot perspective and make that work. The new case can be handled by standard passage, along the lines that Raymond suggested, i.e. just checking for it first.

For x86 we don't need this path as there is no bloblist in TPL, i.e. it can be placed in DRAM from the start.

A fixed address is a bad API for the U-Boot case and is what makes this all so confusing. And no, we can't put it in DRAM on x86 either, that's what had coral broke until I put it back in CAR.

Please explain why a fixed address is a better API than passing a known valid location via register, for the U-Boot case. I don't like it because it means that we cannot always safely check if it exists.

Quoted 7 lines
Quoted 2 lines

--
Tom

Yes I would rather pass the location via register using standard passage, at least on ARM, where we have a suitable protocol. For now this is the only way for me to provide a series where VBE actually works in the lab.

I don't understand why you don't just add what U-Boot is missing then for passage via register.

Signature · 1 line
Tom
#80 lore raw

Re: [PATCH v2 35/35] bloblist: Allow using a different bloblist address

Hi Tom,

Quoted 69 lines · Tom Rini
Quoted 67 lines · Simon Glass

Hi Tom,

Quoted 32 lines · Tom Rini
Quoted 30 lines · Simon Glass

Hi Tom,

Quoted 26 lines · Tom Rini
Quoted 8 lines · Simon Glass

Where the bloblist is located in internal memory and TF-A's BL31 blob removes access to this memory, the best option seems to be to relocate the bloblist just before running TF-A.

We can do the relocation in board-specific code, but need an option to pick up the correct address within U-Boot proper.

Quoted 8 lines

---

Changes in v2:
- Move the actual relocation code to a previous board-specific patch

 common/Kconfig    | 20 ++++++++++++++++++++
 common/bloblist.c | 15 ++++++++++++++-
 2 files changed, 34 insertions(+), 1 deletion(-)

I'm going to NAK this whole concept. The whole nightmare thread about these platforms comes from using a fixed address. We need to pass in a bloblist or see that one is not passed to us, via register. And then use that mechanism to pass the bloblist to the next phase. When we don't have a bloblist passed to us, we allocate one, and not at a fixed location.

Quoted 8 lines
Quoted 2 lines

Well I understand that Linaro may be doing some work to head in that direction.

Are they? I don't know. I know Raymond was doing some clean up based on the idea of treating bloblist and standard passage as two separate things. Which I think is a terrible idea, despite suggesting it. But I think it's also the only way to make progress now that you've decided you can't work with them anymore.

Can't work with who? Linaro? If you don't allow me to create patches for bloblist within your tree, what am I to do?

Quoted 19 lines
Quoted 8 lines

The 'piror-stage' stuff is what has made this all too hard and confusing. We should think of things from a U-Boot perspective and make that work. The new case can be handled by standard passage, along the lines that Raymond suggested, i.e. just checking for it first.

For x86 we don't need this path as there is no bloblist in TPL, i.e. it can be placed in DRAM from the start.

A fixed address is a bad API for the U-Boot case and is what makes this all so confusing. And no, we can't put it in DRAM on x86 either, that's what had coral broke until I put it back in CAR.

Please explain why a fixed address is a better API than passing a known valid location via register, for the U-Boot case. I don't like it because it means that we cannot always safely check if it exists.

--
Tom

Quoted 7 lines
Quoted 4 lines

Yes I would rather pass the location via register using standard passage, at least on ARM, where we have a suitable protocol. For now this is the only way for me to provide a series where VBE actually works in the lab.

I don't understand why you don't just add what U-Boot is missing then for passage via register.

It's too difficult for me, with all the prior-stage and OF_BLOBLIST arguments.

Regards,
Simon

#81 lore raw

Re: [PATCH v2 35/35] bloblist: Allow using a different bloblist address

Quoted 77 lines · Simon Glass

Hi Tom,

Quoted 74 lines · Tom Rini
Quoted 71 lines · Simon Glass

Hi Tom,

Quoted 32 lines · Tom Rini
Quoted 30 lines · Simon Glass

Hi Tom,

Quoted 26 lines · Tom Rini
Quoted 8 lines · Simon Glass

Where the bloblist is located in internal memory and TF-A's BL31 blob removes access to this memory, the best option seems to be to relocate the bloblist just before running TF-A.

We can do the relocation in board-specific code, but need an option to pick up the correct address within U-Boot proper.

Quoted 8 lines

---

Changes in v2:
- Move the actual relocation code to a previous board-specific patch

 common/Kconfig    | 20 ++++++++++++++++++++
 common/bloblist.c | 15 ++++++++++++++-
 2 files changed, 34 insertions(+), 1 deletion(-)

I'm going to NAK this whole concept. The whole nightmare thread about these platforms comes from using a fixed address. We need to pass in a bloblist or see that one is not passed to us, via register. And then use that mechanism to pass the bloblist to the next phase. When we don't have a bloblist passed to us, we allocate one, and not at a fixed location.

Quoted 8 lines
Quoted 2 lines

Well I understand that Linaro may be doing some work to head in that direction.

Are they? I don't know. I know Raymond was doing some clean up based on the idea of treating bloblist and standard passage as two separate things. Which I think is a terrible idea, despite suggesting it. But I think it's also the only way to make progress now that you've decided you can't work with them anymore.

Can't work with who? Linaro? If you don't allow me to create patches for bloblist within your tree, what am I to do?

Quoted 13 lines
Quoted 8 lines

The 'piror-stage' stuff is what has made this all too hard and confusing. We should think of things from a U-Boot perspective and make that work. The new case can be handled by standard passage, along the lines that Raymond suggested, i.e. just checking for it first.

For x86 we don't need this path as there is no bloblist in TPL, i.e. it can be placed in DRAM from the start.

A fixed address is a bad API for the U-Boot case and is what makes this all so confusing. And no, we can't put it in DRAM on x86 either, that's what had coral broke until I put it back in CAR.

Quoted 6 lines

Please explain why a fixed address is a better API than passing a known valid location via register, for the U-Boot case. I don't like it because it means that we cannot always safely check if it exists.

--
Tom

Yes I would rather pass the location via register using standard passage, at least on ARM, where we have a suitable protocol. For now this is the only way for me to provide a series where VBE actually works in the lab.

Quoted 4 lines
Quoted 2 lines

I don't understand why you don't just add what U-Boot is missing then for passage via register.

It's too difficult for me, with all the prior-stage and OF_BLOBLIST arguments.

I'm not sure what to tell you then. I don't want BLOBLIST (which is not standard passage anymore, to appease you) using fixed addresses because that's a bad design and I'm sorry I missed that part originally. I swear I thought it was just temporary or only a starting point.

Signature · 1 line
Tom
#82 lore raw

Re: [PATCH v2 35/35] bloblist: Allow using a different bloblist address

Hi Tom,

Quoted 82 lines · Tom Rini
Quoted 80 lines · Simon Glass

Hi Tom,

Quoted 76 lines · Tom Rini
Quoted 64 lines · Simon Glass

Hi Tom,

Quoted 32 lines · Tom Rini
Quoted 30 lines · Simon Glass

Hi Tom,

Quoted 26 lines · Tom Rini
Quoted 8 lines · Simon Glass

Where the bloblist is located in internal memory and TF-A's BL31 blob removes access to this memory, the best option seems to be to relocate the bloblist just before running TF-A.

We can do the relocation in board-specific code, but need an option to pick up the correct address within U-Boot proper.

Quoted 8 lines

---

Changes in v2:
- Move the actual relocation code to a previous board-specific patch

 common/Kconfig    | 20 ++++++++++++++++++++
 common/bloblist.c | 15 ++++++++++++++-
 2 files changed, 34 insertions(+), 1 deletion(-)

I'm going to NAK this whole concept. The whole nightmare thread about these platforms comes from using a fixed address. We need to pass in a bloblist or see that one is not passed to us, via register. And then use that mechanism to pass the bloblist to the next phase. When we don't have a bloblist passed to us, we allocate one, and not at a fixed location.

Quoted 8 lines
Quoted 2 lines

Well I understand that Linaro may be doing some work to head in that direction.

Are they? I don't know. I know Raymond was doing some clean up based on the idea of treating bloblist and standard passage as two separate things. Which I think is a terrible idea, despite suggesting it. But I think it's also the only way to make progress now that you've decided you can't work with them anymore.

Can't work with who? Linaro? If you don't allow me to create patches for bloblist within your tree, what am I to do?

Quoted 17 lines
Quoted 8 lines

The 'piror-stage' stuff is what has made this all too hard and confusing. We should think of things from a U-Boot perspective and make that work. The new case can be handled by standard passage, along the lines that Raymond suggested, i.e. just checking for it first.

For x86 we don't need this path as there is no bloblist in TPL, i.e. it can be placed in DRAM from the start.

A fixed address is a bad API for the U-Boot case and is what makes this all so confusing. And no, we can't put it in DRAM on x86 either, that's what had coral broke until I put it back in CAR.

Please explain why a fixed address is a better API than passing a known valid location via register, for the U-Boot case. I don't like it because it means that we cannot always safely check if it exists.

Quoted 7 lines
Quoted 2 lines

--
Tom

Yes I would rather pass the location via register using standard passage, at least on ARM, where we have a suitable protocol. For now this is the only way for me to provide a series where VBE actually works in the lab.

I don't understand why you don't just add what U-Boot is missing then for passage via register.

Quoted 6 lines
Quoted 1 line

It's too difficult for me, with all the prior-stage and OF_BLOBLIST arguments.

I'm not sure what to tell you then. I don't want BLOBLIST (which is not standard passage anymore, to appease you) using fixed addresses because that's a bad design and I'm sorry I missed that part originally. I swear I thought it was just temporary or only a starting point.

Well this was 7 years ago, long before I even came up with standard passage[2] where I see that I naively relicensed bloblist because I thought ARM/Linaro might use the code.

We still don't have a solution for x86, of course, the main user of bloblist today.

Regards,
SImon

[1] https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/
[2] https://lore.kernel.org/u-boot/[email protected]/