From 6874cb72204ffbdbe4290baae11d0b9b8ed47ed1 Mon Sep 17 00:00:00 2001 From: Marek Vasut Date: Sun, 9 Jun 2019 03:46:21 +0200 Subject: watchdog: Split WDT from SPL_WDT Use CONFIG_IS_ENABLED(WDT) to permit use of WDT in SPL without DM, while the full U-Boot can use rich DM/DT WDT driver. Signed-off-by: Marek Vasut Cc: Peng Fan Cc: Stefano Babic Tested-by: Heiko Schocher Tested-by: Suniel Mahesh --- common/spl/Kconfig | 1 + common/spl/spl.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) (limited to 'common/spl') diff --git a/common/spl/Kconfig b/common/spl/Kconfig index 5978fb2934..81bd908f9b 100644 --- a/common/spl/Kconfig +++ b/common/spl/Kconfig @@ -1061,6 +1061,7 @@ endif config SPL_WATCHDOG_SUPPORT bool "Support watchdog drivers" + imply SPL_WDT if !HW_WATCHDOG help Enable support for watchdog drivers in SPL. A watchdog is typically a hardware peripheral which can reset the system when it diff --git a/common/spl/spl.c b/common/spl/spl.c index d5e3f680f4..c182705b3f 100644 --- a/common/spl/spl.c +++ b/common/spl/spl.c @@ -603,7 +603,7 @@ void board_init_r(gd_t *dummy1, ulong dummy2) spl_board_init(); #endif -#if defined(CONFIG_SPL_WATCHDOG_SUPPORT) && defined(CONFIG_WDT) +#if defined(CONFIG_SPL_WATCHDOG_SUPPORT) && CONFIG_IS_ENABLED(WDT) initr_watchdog(); #endif -- cgit