From: Marcus Folkesson <marcus.folkesson@gmail.com>
To: Wim Van Sebroeck <wim@iguana.be>, Guenter Roeck <linux@roeck-us.net>
Cc: Marcus Folkesson <marcus.folkesson@gmail.com>,
linux-watchdog@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH 2/4] watchdog: omap_wdt: change order for setting default timeout
Date: Sat, 10 Feb 2018 21:36:21 +0100 [thread overview]
Message-ID: <20180210203623.17832-2-marcus.folkesson@gmail.com> (raw)
In-Reply-To: <20180210203623.17832-1-marcus.folkesson@gmail.com>
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>
---
drivers/watchdog/omap_wdt.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/watchdog/omap_wdt.c b/drivers/watchdog/omap_wdt.c
index 1b02bfa81b29..ae77112ce97f 100644
--- a/drivers/watchdog/omap_wdt.c
+++ b/drivers/watchdog/omap_wdt.c
@@ -253,10 +253,10 @@ static int omap_wdt_probe(struct platform_device *pdev)
wdev->wdog.ops = &omap_wdt_ops;
wdev->wdog.min_timeout = TIMER_MARGIN_MIN;
wdev->wdog.max_timeout = TIMER_MARGIN_MAX;
+ wdev->wdog.timeout = TIMER_MARGIN_DEFAULT;
wdev->wdog.parent = &pdev->dev;
- if (watchdog_init_timeout(&wdev->wdog, timer_margin, &pdev->dev) < 0)
- wdev->wdog.timeout = TIMER_MARGIN_DEFAULT;
+ watchdog_init_timeout(&wdev->wdog, timer_margin, &pdev->dev);
watchdog_set_nowayout(&wdev->wdog, nowayout);
--
2.15.1
next prev parent reply other threads:[~2018-02-10 20:36 UTC|newest]
Thread overview: 9+ 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 ` Marcus Folkesson [this message]
2018-02-11 3:54 ` [PATCH 2/4] watchdog: omap_wdt: " Guenter Roeck
2018-02-10 20:36 ` [PATCH 3/4] watchdog: gpio: " Marcus Folkesson
2018-02-11 3:55 ` Guenter Roeck
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 ` [PATCH 1/4] watchdog: uniphier: change order for setting default timeout Guenter Roeck
2018-02-21 1:29 ` 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=20180210203623.17832-2-marcus.folkesson@gmail.com \
--to=marcus.folkesson@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-watchdog@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=wim@iguana.be \
/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).