mx7ulp: soc: s_init should only be executed once
Subsystems (3)
PATCH 1/1 mx7ulp: soc: s_init should only be executed once
On SPL enabled systems, the current s_init code (wdog, clock and ldo init) is executed twice (by SPL and u-boot). This is not necessary and might lead to boot issues (ie, starting PMC1 when it is already running).
--- arch/arm/mach-imx/mx7ulp/soc.c | 2 ++ 1 file changed, 2 insertions(+)
arch/arm/mach-imx/mx7ulp/soc.c +2 -0
@@ -117,6 +117,7 @@ void init_wdog(void)disable_wdog (WDG2_RBASE ); } +#if !defined(CONFIG_SPL) || (defined(CONFIG_SPL) && defined(CONFIG_SPL_BUILD)) #if defined(CONFIG_LDO_ENABLED_MODE) static void init_ldo_mode(void) {
@@ -174,6 +175,7 @@ void s_init(void)#endif return; } +#endif #ifndef CONFIG_ULP_WATCHDOG void reset_cpu (ulong addr)
Signature · 1 line
2.17.1
Fabio Estevam
reviewerPATCH 1/1 mx7ulp: soc: s_init should only be executed once
Hi Jorge,
Quoted 6 lines · Jorge Ramirez-Ortiz
On SPL enabled systems, the current
s_initcode (wdog, clock and ldo init) is executed twice (by SPL and u-boot). This is not necessary and might lead to boot issues (ie, starting PMC1 when it is already running).Signed-off-by Jorge Ramirez-Ortiz <[email protected]>
The target I use to test LDO-enabled mode does not use SPL, so that's why I did not notice the problem.
Thanks for the fix:
Jorge Ramirez-Ortiz
PATCH 1/1 mx7ulp: soc: s_init should only be executed once
Quoted 8 lines · Fabio Estevam
Hi Jorge,
Quoted 5 lines · Jorge Ramirez-Ortiz
On SPL enabled systems, the current
s_initcode (wdog, clock and ldo init) is executed twice (by SPL and u-boot). This is not necessary and might lead to boot issues (ie, starting PMC1 when it is already running).
Quoted 6 lines
Quoted 1 line
Signed-off-by Jorge Ramirez-Ortiz <[email protected]>The target I use to test LDO-enabled mode does not use SPL, so that's why I did not notice the problem.
Thanks for the fix:
Hi Favio,
sorry I forgot to mention: this does not fix the issue I see when executing the LDO init code - that still locks when run from SPL or U-Boot. This commit is just because I noticed that s_init was being called twice (for SPL and U-Boot) and I dont think it makes sense.
Quoted 2 lines
Reviewed-by Fabio Estevam <[email protected]>
Jorge Ramirez-Ortiz
PATCH 1/1 mx7ulp: soc: s_init should only be executed once
Quoted 14 lines · Gmail
Quoted 13 lines · Fabio Estevam
Hi Jorge,
Quoted 6 lines · Jorge Ramirez-Ortiz
On SPL enabled systems, the current
s_initcode (wdog, clock and ldo init) is executed twice (by SPL and u-boot). This is not necessary and might lead to boot issues (ie, starting PMC1 when it is already running).Signed-off-by Jorge Ramirez-Ortiz <[email protected]>The target I use to test LDO-enabled mode does not use SPL, so that's why I did not notice the problem.
Quoted 9 lines
Quoted 1 line
Thanks for the fix:
Hi Favio,
sorry I forgot to mention: this does not fix the issue I see when executing the LDO init code - that still locks when run from SPL or U-Boot. This commit is just because I noticed that
s_initwas being called twice (for SPL and U-Boot) and I dont think it makes sense.Quoted 2 lines
Reviewed-by Fabio Estevam <[email protected]>
hi Favio/all
plese could you confirm if this patch will be merged (just so we dont have to carry it separately in our product branches)
thanks!
Jorge
Fabio Estevam
reviewerPATCH 1/1 mx7ulp: soc: s_init should only be executed once
Hi Jorge,
Quoted 3 lines · Foundries
hi Favio/all
plese could you confirm if this patch will be merged (just so we dont have to carry it separately in our product branches)
Yes, I think it makes sense to apply it. I have already given my Reviewed-by tag.
PATCH 1/1 mx7ulp: soc: s_init should only be executed once
In reply to Jorge Ramirez-OrtizQuoted 5 lines
On SPL enabled systems, the current
s_initcode (wdog, clock and ldo init) is executed twice (by SPL and u-boot). This is not necessary and might lead to boot issues (ie, starting PMC1 when it is already running).Signed-off-by Jorge Ramirez-Ortiz <[email protected]>Reviewed-by Fabio Estevam <[email protected]>
Applied to u-boot-imx, master, thanks !
Best regards,
Stefano Babic
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de =====================================================================