From: matthias.bgg at kernel.org Date: Thu, 7 Jan 2021 16:36:38 +0100 Subject: [PATCH] board: mediatek: disable watchdog on BananaPi R2 Message-ID: <20210107153638.15241-1-matthias.bgg@kernel.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de From: Matthias Brugger Watchdog timeout comes in before we are able to load the kernel and reset the watchdog. Disable the watchdog late in the boot process to be able to boot the board. Signed-off-by: Matthias Brugger --- board/mediatek/mt7623/mt7623_rfb.c | 8 ++++++++ configs/mt7623n_bpir2_defconfig | 1 + 2 files changed, 9 insertions(+) diff --git a/board/mediatek/mt7623/mt7623_rfb.c b/board/mediatek/mt7623/mt7623_rfb.c index 984e75ccaf..22120be412 100644 --- a/board/mediatek/mt7623/mt7623_rfb.c +++ b/board/mediatek/mt7623/mt7623_rfb.c @@ -5,6 +5,7 @@ #include #include +#include DECLARE_GLOBAL_DATA_PTR; @@ -40,3 +41,10 @@ int mmc_get_env_dev(void) return mmc_get_boot_dev(); } #endif + +#ifdef CONFIG_BOARD_LATE_INIT +int board_late_init(void) +{ + wdt_stop(gd->watchdog_dev); +} +#endif diff --git a/configs/mt7623n_bpir2_defconfig b/configs/mt7623n_bpir2_defconfig index 9177c17dff..fe0b6259dd 100644 --- a/configs/mt7623n_bpir2_defconfig +++ b/configs/mt7623n_bpir2_defconfig @@ -14,6 +14,7 @@ CONFIG_FIT_VERBOSE=y CONFIG_BOOTDELAY=3 CONFIG_SYS_CONSOLE_IS_IN_ENV=y CONFIG_DEFAULT_FDT_FILE="mt7623n-bananapi-bpi-r2.dtb" +CONFIG_BOARD_LATE_INIT=y # CONFIG_DISPLAY_BOARDINFO is not set CONFIG_SYS_PROMPT="U-Boot> " CONFIG_CMD_BOOTMENU=y -- 2.29.2