linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: linux@roeck-us.net (Guenter Roeck)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/4] watchdog: uniphier: change order for setting default timeout
Date: Sat, 10 Feb 2018 19:54:09 -0800	[thread overview]
Message-ID: <2427b67d-7d4f-e82f-a6bf-cb51a75a67dc@roeck-us.net> (raw)
In-Reply-To: <20180210203623.17832-1-marcus.folkesson@gmail.com>

On 02/10/2018 12:36 PM, Marcus Folkesson wrote:
> watchdog_init_timeout() will preserve wdd->timeout value if no parameter
> nor timeout-secs dt property is set.
> 
> Signed-off-by: Marcus Folkesson <marcus.folkesson@gmail.com>

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

> ---
>   drivers/watchdog/uniphier_wdt.c | 5 ++---
>   1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/watchdog/uniphier_wdt.c b/drivers/watchdog/uniphier_wdt.c
> index 0ea2339d9702..0e4f8d53ce3c 100644
> --- a/drivers/watchdog/uniphier_wdt.c
> +++ b/drivers/watchdog/uniphier_wdt.c
> @@ -212,11 +212,10 @@ static int uniphier_wdt_probe(struct platform_device *pdev)
>   	wdev->wdt_dev.ops = &uniphier_wdt_ops;
>   	wdev->wdt_dev.max_timeout = WDT_PERIOD_MAX;
>   	wdev->wdt_dev.min_timeout = WDT_PERIOD_MIN;
> +	wdev->wdt_dev.timeout = WDT_DEFAULT_TIMEOUT;
>   	wdev->wdt_dev.parent = dev;
>   
> -	if (watchdog_init_timeout(&wdev->wdt_dev, timeout, dev) < 0) {
> -		wdev->wdt_dev.timeout = WDT_DEFAULT_TIMEOUT;
> -	}
> +	watchdog_init_timeout(&wdev->wdt_dev, timeout, dev);
>   	watchdog_set_nowayout(&wdev->wdt_dev, nowayout);
>   	watchdog_stop_on_reboot(&wdev->wdt_dev);
>   
> 

  parent reply	other threads:[~2018-02-11  3:54 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-10 20:36 [PATCH 1/4] watchdog: uniphier: change order for setting default timeout Marcus Folkesson
2018-02-10 20:36 ` [PATCH 4/4] watchdog: lpc18xx: remove assignment of unused ret-value Marcus Folkesson
2018-02-11  3:56   ` Guenter Roeck
2018-02-11  3:54 ` Guenter Roeck [this message]
2018-02-21  1:29 ` [PATCH 1/4] watchdog: uniphier: change order for setting default timeout Masahiro Yamada

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2427b67d-7d4f-e82f-a6bf-cb51a75a67dc@roeck-us.net \
    --to=linux@roeck-us.net \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).