diff mbox series

[1/2] watchdog: orion_wdt: remove orion_wdt_set_timeout

Message ID 20190304225152.26831-2-chris.packham@alliedtelesis.co.nz (mailing list archive)
State Accepted
Headers show
Series watchdog: orion_wdt: add pretimeout support | expand

Commit Message

Chris Packham March 4, 2019, 10:51 p.m. UTC
The watchdog core will do the same thing if no set_timeout
is supplied so we can safely remove orion_wdt_set_timeout.

Signed-off-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
---
 drivers/watchdog/orion_wdt.c | 8 --------
 1 file changed, 8 deletions(-)

Comments

Guenter Roeck March 5, 2019, 5:17 p.m. UTC | #1
On Tue, Mar 05, 2019 at 11:51:51AM +1300, Chris Packham wrote:
> The watchdog core will do the same thing if no set_timeout
> is supplied so we can safely remove orion_wdt_set_timeout.
> 
> Signed-off-by: Chris Packham <chris.packham@alliedtelesis.co.nz>

Reviewed-by: Guenter Roeck <linux@roeck-us.net>

> ---
>  drivers/watchdog/orion_wdt.c | 8 --------
>  1 file changed, 8 deletions(-)
> 
> diff --git a/drivers/watchdog/orion_wdt.c b/drivers/watchdog/orion_wdt.c
> index 9db3b09f7568..8b259c712c52 100644
> --- a/drivers/watchdog/orion_wdt.c
> +++ b/drivers/watchdog/orion_wdt.c
> @@ -349,13 +349,6 @@ static unsigned int orion_wdt_get_timeleft(struct watchdog_device *wdt_dev)
>  	return readl(dev->reg + dev->data->wdt_counter_offset) / dev->clk_rate;
>  }
>  
> -static int orion_wdt_set_timeout(struct watchdog_device *wdt_dev,
> -				 unsigned int timeout)
> -{
> -	wdt_dev->timeout = timeout;
> -	return 0;
> -}
> -
>  static const struct watchdog_info orion_wdt_info = {
>  	.options = WDIOF_SETTIMEOUT | WDIOF_KEEPALIVEPING | WDIOF_MAGICCLOSE,
>  	.identity = "Orion Watchdog",
> @@ -366,7 +359,6 @@ static const struct watchdog_ops orion_wdt_ops = {
>  	.start = orion_wdt_start,
>  	.stop = orion_wdt_stop,
>  	.ping = orion_wdt_ping,
> -	.set_timeout = orion_wdt_set_timeout,
>  	.get_timeleft = orion_wdt_get_timeleft,
>  };
>  
> -- 
> 2.21.0
>
diff mbox series

Patch

diff --git a/drivers/watchdog/orion_wdt.c b/drivers/watchdog/orion_wdt.c
index 9db3b09f7568..8b259c712c52 100644
--- a/drivers/watchdog/orion_wdt.c
+++ b/drivers/watchdog/orion_wdt.c
@@ -349,13 +349,6 @@  static unsigned int orion_wdt_get_timeleft(struct watchdog_device *wdt_dev)
 	return readl(dev->reg + dev->data->wdt_counter_offset) / dev->clk_rate;
 }
 
-static int orion_wdt_set_timeout(struct watchdog_device *wdt_dev,
-				 unsigned int timeout)
-{
-	wdt_dev->timeout = timeout;
-	return 0;
-}
-
 static const struct watchdog_info orion_wdt_info = {
 	.options = WDIOF_SETTIMEOUT | WDIOF_KEEPALIVEPING | WDIOF_MAGICCLOSE,
 	.identity = "Orion Watchdog",
@@ -366,7 +359,6 @@  static const struct watchdog_ops orion_wdt_ops = {
 	.start = orion_wdt_start,
 	.stop = orion_wdt_stop,
 	.ping = orion_wdt_ping,
-	.set_timeout = orion_wdt_set_timeout,
 	.get_timeleft = orion_wdt_get_timeleft,
 };