]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
configs: meson64_android: bypass other checks on run_fastboot=1
authorNeil Armstrong <narmstrong@baylibre.com>
Wed, 17 Nov 2021 11:04:10 +0000 (12:04 +0100)
committerNeil Armstrong <narmstrong@baylibre.com>
Fri, 19 Nov 2021 17:15:26 +0000 (18:15 +0100)
This can lead to GPT and BCB errors even if fastboot was selected early
by usb rom boot and the eMMC is blank/invalid.

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

index fb3ccc329a7ec0f03a804b7532752d193eef3f98..93d8f8ec99de6b760dcc5971a7dec7840fe529d8 100644 (file)
                        "echo Fastboot forced by usb rom boot;" \
                        "setenv run_fastboot 1;" \
                "fi;" \
-               "if gpt verify mmc ${mmcdev} ${partitions}; then; " \
-               "else " \
-                       "echo Broken MMC partition scheme;" \
-                       "setenv run_fastboot 1;" \
-               "fi;" \
-               "if bcb load " __stringify(CONFIG_FASTBOOT_FLASH_MMC_DEV) " " \
-               CONTROL_PARTITION "; then " \
-                       "if bcb test command = bootonce-bootloader; then " \
-                               "echo BCB: Bootloader boot...; " \
-                               "bcb clear command; bcb store; " \
+               "if test \"${run_fastboot}\" -eq 0; then " \
+                       "if gpt verify mmc ${mmcdev} ${partitions}; then; " \
+                       "else " \
+                               "echo Broken MMC partition scheme;" \
                                "setenv run_fastboot 1;" \
                        "fi; " \
-                       "if bcb test command = boot-fastboot; then " \
-                               "echo BCB: fastboot userspace boot...; " \
-                               "setenv force_recovery 1;" \
-                       "fi; " \
-               "else " \
-                       "echo Warning: BCB is corrupted or does not exist; " \
+               "fi;" \
+               "if test \"${run_fastboot}\" -eq 0; then " \
+                       "if bcb load " __stringify(CONFIG_FASTBOOT_FLASH_MMC_DEV) " " \
+                       CONTROL_PARTITION "; then " \
+                               "if bcb test command = bootonce-bootloader; then " \
+                                       "echo BCB: Bootloader boot...; " \
+                                       "bcb clear command; bcb store; " \
+                                       "setenv run_fastboot 1;" \
+                               "elif bcb test command = boot-fastboot; then " \
+                                       "echo BCB: fastboot userspace boot...; " \
+                                       "setenv force_recovery 1;" \
+                               "fi; " \
+                       "else " \
+                               "echo Warning: BCB is corrupted or does not exist; " \
+                       "fi;" \
                "fi;" \
                "if test \"${run_fastboot}\" -eq 1; then " \
                        "echo Running Fastboot...;" \