From: Marek Szyprowski Date: Mon, 21 Dec 2020 10:25:56 +0000 (+0100) Subject: tizen: move Function button check to separate env script X-Git-Tag: submit/tizen/20201222.005612^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9139b469952556fcadcb3371d6e19eaa66e02673;p=platform%2Fkernel%2Fu-boot.git tizen: move Function button check to separate env script This will make CONFIG_PREBOOT a bit more readable and easier to understand. Signed-off-by: Marek Szyprowski Change-Id: I75d0e42a6b26c7e4c5d7d4818e9e0f450151a1b2 --- diff --git a/configs/khadas-vim3_defconfig b/configs/khadas-vim3_defconfig index df716b4165..0af5bf2fb6 100644 --- a/configs/khadas-vim3_defconfig +++ b/configs/khadas-vim3_defconfig @@ -15,7 +15,7 @@ CONFIG_DEFAULT_DEVICE_TREE="meson-g12b-a311d-khadas-vim3" CONFIG_DEBUG_UART=y CONFIG_OF_BOARD_SETUP=y CONFIG_USE_PREBOOT=y -CONFIG_PREBOOT="run mbr_check; echo Checking Func button state (for THOR download mode): \\\\\\\\c; sleep 0.25; if button Function; then thor; fi; run reboot_check" +CONFIG_PREBOOT="run mbr_check; run button_check; run reboot_check" # CONFIG_CONSOLE_MUX is not set CONFIG_MISC_INIT_R=y # CONFIG_DISPLAY_CPUINFO is not set diff --git a/configs/khadas-vim3l_defconfig b/configs/khadas-vim3l_defconfig index c142057aee..ca7e0e3c2a 100644 --- a/configs/khadas-vim3l_defconfig +++ b/configs/khadas-vim3l_defconfig @@ -15,7 +15,7 @@ CONFIG_DEFAULT_DEVICE_TREE="meson-sm1-khadas-vim3l" CONFIG_DEBUG_UART=y CONFIG_OF_BOARD_SETUP=y CONFIG_USE_PREBOOT=y -CONFIG_PREBOOT="run mbr_check; echo Checking Func button state (for THOR download mode): \\\\\\\\c; sleep 0.25; if button Function; then thor; fi; run reboot_check" +CONFIG_PREBOOT="run mbr_check; run button_check; run reboot_check" CONFIG_MISC_INIT_R=y # CONFIG_DISPLAY_CPUINFO is not set CONFIG_SYS_PROMPT="Khadas VIM3L> " diff --git a/include/samsung/tizen_amlogic.h b/include/samsung/tizen_amlogic.h index 03a89939d1..dffbe38f9b 100644 --- a/include/samsung/tizen_amlogic.h +++ b/include/samsung/tizen_amlogic.h @@ -135,6 +135,13 @@ "thor; " \ "fi" +#define BUTTON_CHECK \ + "echo Checking Func button state (for THOR download mode): \\\\\\\\c; " \ + "sleep 0.25; " \ + "if button Function; then " \ + "thor; " \ + "fi" + #define TIZEN_ENV_SETTING \ "mmcbootpart=1\0" \ "mmcrootpart=2\0" \ @@ -154,6 +161,7 @@ "boot_prefixes=" TIZEN_BOOT_PREFIX "\0" \ "mbr_parts=" PARTS_DEFAULT "\0" \ "mbr_check=" MBR_CHECK "\0" \ + "button_check=" BUTTON_CHECK "\0" \ "reboot_check=" REBOOT_CHECK "\0" \ "splashimage=0x2000000\0" \ "splashsource=mmc_fs\0" \