]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
configs: meson64_android: define BOOT_CMD macro
authorMattijs Korpershoek <mkorpershoek@baylibre.com>
Thu, 5 Aug 2021 15:17:24 +0000 (17:17 +0200)
committerNeil Armstrong <narmstrong@baylibre.com>
Tue, 10 Aug 2021 08:43:54 +0000 (10:43 +0200)
BOOT_CMD might be different based on CONFIG_CMD_ABOOTIMG.

To prepare for abootimg support, extract the boot command
to a dedicated macro.

Signed-off-by: Guillaume La Roque <glaroque@baylibre.com>
Signed-off-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
Acked-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
include/configs/meson64_android.h

index 83fa25bfb1f0cedd0fda7762f7beb01699857aef..0ce616c17edd5d1914bd0122e9a394cc002b5d57 100644 (file)
@@ -81,6 +81,8 @@
 #define RECOVERY_PARTITION "recovery"
 #endif
 
+#define BOOT_CMD "bootm ${loadaddr};"
+
 #define BOOTENV_DEV_FASTBOOT(devtypeu, devtypel, instance) \
        "bootcmd_fastboot=" \
                "setenv run_fastboot 0;" \
                        "part size mmc ${mmcdev} " RECOVERY_PARTITION "${slot_suffix} boot_size;" \
                        "if mmc read ${loadaddr} ${boot_start} ${boot_size}; then " \
                                "echo Running Android Recovery...;" \
-                               "bootm ${loadaddr};" \
+                               BOOT_CMD \
                        "fi;" \
                        "echo Failed to boot Android...;" \
                        "reset;" \
                "if mmc read ${loadaddr} ${boot_start} ${boot_size}; then " \
                        "setenv bootargs \"${bootargs} " AB_BOOTARGS "\"  ; " \
                        "echo Running Android...;" \
-                       "bootm ${loadaddr};" \
+                       BOOT_CMD \
                "fi;" \
                "echo Failed to boot Android...;" \
                "reset\0"