diff options
author | Jagan Teki <jagan@amarulasolutions.com> | 2017-02-24 15:45:18 +0530 |
---|---|---|
committer | Stefano Babic <sbabic@denx.de> | 2017-03-17 09:27:08 +0100 |
commit | 2e2a8dc635f5ca3be9d96759a905ede73f1baf33 (patch) | |
tree | b56af27285a8cf083212937a1845b8fdc556432e /include | |
parent | 7cf22dc8d87285ba4f82f8a0a9d7b0c33c1b9d74 (diff) | |
download | u-boot-2e2a8dc635f5ca3be9d96759a905ede73f1baf33.zip u-boot-2e2a8dc635f5ca3be9d96759a905ede73f1baf33.tar.gz u-boot-2e2a8dc635f5ca3be9d96759a905ede73f1baf33.tar.bz2 |
i.MX6UL: isiot: Add modeboot env via board_late_init
Add runtime, modeboot env which is setting mmcboot, or
nandboot based on the bootdevice so-that conditional
macros b/w MMC and NAND for CONFIG_BOOTCOMMAND should
be avoided in config files.
Cc: Matteo Lisi <matteo.lisi@engicam.com>
Cc: Michael Trimarchi <michael@amarulasolutions.com>
Reviewed by: Stefano Babic <sbabic@denx.de>
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/configs/imx6ul_isiot.h | 36 |
1 files changed, 16 insertions, 20 deletions
diff --git a/include/configs/imx6ul_isiot.h b/include/configs/imx6ul_isiot.h index 1b0e436..7258fed 100644 --- a/include/configs/imx6ul_isiot.h +++ b/include/configs/imx6ul_isiot.h @@ -64,8 +64,7 @@ "fitboot=echo Booting FIT image from mmc ...; " \ "run mmcargs; " \ "bootm ${loadaddr}\0" \ - "mmcboot=echo Booting from mmc ...; " \ - "run mmcargs; " \ + "_mmcboot=run mmcargs; " \ "if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \ "if run loadfdt; then " \ "bootm ${loadaddr} - ${fdt_addr}; " \ @@ -79,6 +78,20 @@ "else " \ "bootm; " \ "fi\0" \ + "mmcboot=echo Booting from mmc ...; " \ + "if mmc rescan; then " \ + "if run loadbootscript; then " \ + "run bootscript; " \ + "else " \ + "if run loadfit; then " \ + "run fitboot; " \ + "else " \ + "if run loadimage; then " \ + "run _mmcboot; " \ + "fi; " \ + "fi; " \ + "fi; " \ + "fi\0" \ "nandboot=echo Booting from nand ...; " \ "if mtdparts; then " \ "echo Starting nand boot ...; " \ @@ -90,24 +103,7 @@ "nand read ${fdt_addr} dtb 0x100000; " \ "bootm ${loadaddr} - ${fdt_addr}\0" -#ifdef CONFIG_NAND_MXS -# define CONFIG_BOOTCOMMAND "run nandboot" -#else -# define CONFIG_BOOTCOMMAND \ - "if mmc rescan; then " \ - "if run loadbootscript; then " \ - "run bootscript; " \ - "else " \ - "if run loadfit; then " \ - "run fitboot; " \ - "else " \ - "if run loadimage; then " \ - "run mmcboot; " \ - "fi; " \ - "fi; " \ - "fi; " \ - "fi" -#endif +#define CONFIG_BOOTCOMMAND "run $modeboot" /* Miscellaneous configurable options */ #define CONFIG_SYS_MEMTEST_START 0x80000000 |