arm: at91: Remove CONFIG_AT91_HW_WDT_TIMEOUT
authorStefan Roese <sr@denx.de>
Wed, 3 Apr 2019 05:37:05 +0000 (07:37 +0200)
committerEugen Hristev <eugen.hristev@microchip.com>
Tue, 9 Apr 2019 06:28:50 +0000 (09:28 +0300)
This patch removes the CONFIG_AT91_HW_WDT_TIMEOUT as its not needed any
more. The WD timeout value can be provided via the "timeout-sec" DT
property. If not provided this way, the default value of 2 seconds will
be used.

Signed-off-by: Stefan Roese <sr@denx.de>
Cc: Heiko Schocher <hs@denx.de>
Cc: Andreas Bießmann <andreas@biessmann.org>
Cc: Eugen Hristev <eugen.hristev@microchip.com>
README
configs/smartweb_defconfig
configs/taurus_defconfig
drivers/watchdog/Kconfig
drivers/watchdog/at91sam9_wdt.c

diff --git a/README b/README
index c9a20db34f726986ccbb3c34fbc58e92b2d47a25..a514f48caefc68b8453b8cc7ce0da3581f3504a8 100644 (file)
--- a/README
+++ b/README
@@ -767,9 +767,6 @@ The following options need to be configured:
                SoC, then define this variable and provide board
                specific code for the "hw_watchdog_reset" function.
 
-               CONFIG_AT91_HW_WDT_TIMEOUT
-               specify the timeout in seconds. default 2 seconds.
-
 - Real-Time Clock:
 
                When CONFIG_CMD_DATE is selected, the type of the RTC
index 7c7220afc81b2732c01353f9f2f9fa019199f20f..807a5691210b4b2eca4e16de2ffd729b83e6dbc1 100644 (file)
@@ -59,6 +59,5 @@ CONFIG_USB_ETHER_ASIX=y
 CONFIG_USB_ETHER_MCS7830=y
 CONFIG_WDT=y
 CONFIG_WDT_AT91=y
-CONFIG_AT91_HW_WDT_TIMEOUT=y
 CONFIG_SPL_TINY_MEMSET=y
 # CONFIG_EFI_LOADER is not set
index 022b0b6da194c530dc6d4fc6ea386eb78e8809f0..d69f4895eff3309a7d2b2b4e31faee7ad8297b8e 100644 (file)
@@ -62,5 +62,4 @@ CONFIG_USB_GADGET_PRODUCT_NUM=0x02d2
 CONFIG_USB_GADGET_DOWNLOAD=y
 CONFIG_WDT=y
 CONFIG_WDT_AT91=y
-CONFIG_AT91_HW_WDT_TIMEOUT=y
 CONFIG_USE_TINY_PRINTF=y
index 115fc4551ffd0853cb1c4951a6cb885cf145d461..34e78beb2a66f8f6d7afd54409e718f6902f08ba 100644 (file)
@@ -139,10 +139,6 @@ config WDT_AT91
           Select this to enable Microchip watchdog timer, which can be found on
           some AT91 devices.
 
-config AT91_HW_WDT_TIMEOUT
-       bool "AT91 watchdog timeout specified"
-       depends on WDT_AT91
-
 config WDT_MT7621
        bool "MediaTek MT7621 watchdog timer support"
        depends on WDT && ARCH_MT7620
index b0a3b4ed58636a945f7355d2ce0d33b791a7086c..a9fd547e2f7ef5091b73cf4409653b29ecc78656 100644 (file)
@@ -117,10 +117,12 @@ static int at91_wdt_probe(struct udevice *dev)
        if (!priv->regs)
                return -EINVAL;
 
-#ifdef CONFIG_AT91_HW_WDT_TIMEOUT
+#if CONFIG_IS_ENABLED(OF_CONTROL)
        priv->timeout = dev_read_u32_default(dev, "timeout-sec",
                                             WDT_DEFAULT_TIMEOUT);
        debug("%s: timeout %d", __func__, priv->timeout);
+#else
+       priv->timeout = WDT_DEFAULT_TIMEOUT;
 #endif
 
        debug("%s: Probing wdt%u\n", __func__, dev->seq);