include: env: ti: move board specific scripts out of ti_common
PATCH 1/1 include: env: ti: move board specific scripts out of ti_common
bootcmd_ti_mmc had cpsw0_qsgmii_phyinit related scripts even though this was only relevant for the j721e/j7200 SoCs. This patch instead factors out those scripts into a generic 'board_init' which is called as part of bootcmd_ti_mmc.
This allows boards to more easily add custom behaviour to the ti_mmc bootflow instead of having to modify the ti_common.env file.
--- board/ti/j7200/j7200.env | 8 ++++++++ board/ti/j721e/j721e.env | 8 ++++++++ include/env/ti/ti_common.env | 8 +++----- 3 files changed, 19 insertions(+), 5 deletions(-)
board/ti/j7200/j7200.env +8 -0
@@ -37,3 +37,11 @@ main_cpsw0_qsgmii_phyinit= #if CONFIG_TARGET_J7200_A72_EVM rproc_fw_binaries= 1 /lib/firmware/j7200-mcu-r5f0_1-fw 2 /lib/firmware/j7200-main-r5f0_0-fw 3 /lib/firmware/j7200-main-r5f0_1-fw #endif + +#if CONFIG_CMD_REMOTEPROC +board_init= + if env exists do_main_cpsw0_qsgmii_phyinit; + then run main_cpsw0_qsgmii_phyinit; + fi; + run boot_rprocs; +#endif
board/ti/j721e/j721e.env +8 -0
@@ -37,3 +37,11 @@ main_cpsw0_qsgmii_phyinit= #if CONFIG_TARGET_J721E_A72_EVM rproc_fw_binaries= 1 /lib/firmware/j7-mcu-r5f0_1-fw 2 /lib/firmware/j7-main-r5f0_0-fw 3 /lib/firmware/j7-main-r5f0_1-fw 4 /lib/firmware/j7-main-r5f1_0-fw 5 /lib/firmware/j7-main-r5f1_1-fw 6 /lib/firmware/j7-c66_0-fw 7 /lib/firmware/j7-c66_1-fw 8 /lib/firmware/j7-c71_0-fw #endif + +#if CONFIG_CMD_REMOTEPROC +board_init= + if env exists do_main_cpsw0_qsgmii_phyinit; + then run main_cpsw0_qsgmii_phyinit; + fi; + run boot_rprocs; +#endif
include/env/ti/ti_common.env +3 -5
@@ -24,12 +24,10 @@ get_fit_config=setexpr name_fit_config gsub / _ conf-${fdtfile} run_fit=run get_fit_config; bootm ${addr_fit}#${name_fit_config}${overlaystring} bootcmd_ti_mmc= run init_${boot}; -#if CONFIG_CMD_REMOTEPROC - if env exists do_main_cpsw0_qsgmii_phyinit; - then run main_cpsw0_qsgmii_phyinit; + if test -n ${board_init}; then + echo Running board_init ...; + run board_init; fi; - run boot_rprocs; -#endif if test ${boot_fit} -eq 1; then run get_fit_${boot}; run get_fit_overlaystring; run run_fit; else;
---
base-commit: c0ca147ac6228949a6d6497531c9f2f4a0dc6c67
change-id: 20260306-board_init_env_introduce-3da7ec4a1ad3
Best regards,
Signature · 1 line
Anshul Dalal <[email protected]>
Quoted 9 lines · Anshul Dalal
bootcmd_ti_mmchadcpsw0_qsgmii_phyinitrelated scripts even though this was only relevant for the j721e/j7200 SoCs. This patch instead factors out those scripts into a generic 'board_init' which is called as part ofbootcmd_ti_mmc.This allows boards to more easily add custom behaviour to the
ti_mmcbootflow instead of having to modify the ti_common.env file.[...]
Applied to u-boot/next, thanks!
[1/1] include: env: ti: move board specific scripts out of ti_common
commit: e853610b560c072dd7207f2ccff01772aff1b748
Signature · 1 line
Tom