watchdog: Convert ep93xx driver to watchdog core
Convert the ep93xx_wdt driver to the watchdog framework API.
Also, use the dev_<fmt> functions instead of pr_<fmt> for logging.
Signed-off-by H Hartley Sweeten <[email protected]>
Cc Wim Van Sebroeck <[email protected]>
Cc Ryan Mallon <[email protected]>
Cc Mika Westerberg <[email protected]>
---
drivers/watchdog/Kconfig +1 -0
@@ -217,6 +217,7 @@ config MPCORE_WATCHDOG config EP93XX_WATCHDOG tristate "EP93xx Watchdog" depends on ARCH_EP93XX + select WATCHDOG_CORE help Say Y here if to include support for the watchdog timer embedded in the Cirrus Logic EP93xx family of devices.
drivers/watchdog/ep93xx_wdt.c +54 -149
290 lines not on this page · raw message
Quoted 8 lines · H Hartley Sweeten
Convert the
ep93xx_wdtdriver to the watchdog framework API.Also, use the dev_<fmt> functions instead of pr_<fmt> for logging.
Signed-off-by H Hartley Sweeten <[email protected]>Cc Wim Van Sebroeck <[email protected]>Cc Ryan Mallon <[email protected]>Cc Mika Westerberg <[email protected]>
While testing this I noticed that you missed to set the initial timeout of the wdt device. Otherwise doing WDIOC_GETTIMEOUT fails.
With that fixed,
Reviewed-by Mika Westerberg <[email protected]>
Tested-by Mika Westerberg <[email protected]>
drivers/watchdog/ep93xx_wdt.c +1 -0
@@ -139,6 +139,7 @@ static int __devinit ep93xx_wdt_probe(struct platform_device *pdev) val =readl (mmio_base +EP93XX_WATCHDOG ); ep93xx_wdt_wdd.bootstatus = (val &0x01 ) ?WDIOF_CARDRESET :0 ; + ep93xx_wdt_wdd.timeout = timeout;watchdog_set_nowayout (&ep93xx_wdt_wdd, nowayout);