aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorEduard Strehlau2023-04-26 13:04:52 -0300
committerStefano Babic2023-05-02 10:57:32 +0200
commit440dc0694ba44ed8551f8809f76373f20800987f (patch)
tree53f1ac2b075e8c1a1793a51644891fa8a5083e6c /include
parentac52bb99cc7c9c288432f80710b21bd54e743f58 (diff)
smegw01: Run altbootcmd in the case of failure
Run the altbootcmd script if any step of bootcmd fails. This ensures that always a valid image can be run. Signed-off-by: Eduard Strehlau <eduard@lionizers.com> Signed-off-by: Fabio Estevam <festevam@denx.de>
Diffstat (limited to 'include')
-rw-r--r--include/configs/smegw01.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/include/configs/smegw01.h b/include/configs/smegw01.h
index 6ee4acc70d2..05edaac42f8 100644
--- a/include/configs/smegw01.h
+++ b/include/configs/smegw01.h
@@ -39,7 +39,13 @@
"mmcboot=echo Booting from mmc ...; " \
"run mmcargs; " \
"if run loadfdt; then " \
- "bootz ${loadaddr} - ${fdt_addr}; " \
+ "if bootz ${loadaddr} - ${fdt_addr}; then " \
+ "; " \
+ "else " \
+ "run altbootcmd; " \
+ "fi;" \
+ "else " \
+ "run altbootcmd; " \
"fi;\0" \
"altbootcmd=echo Performing rollback...; " \
"if test \"${mmcpart}\" = 1; then " \