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 3/4] watchdog: gpio: change order for setting default timeout
Date: Sat, 10 Feb 2018 21:36:22 +0100 [thread overview]
Message-ID: <20180210203623.17832-3-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/gpio_wdt.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/watchdog/gpio_wdt.c b/drivers/watchdog/gpio_wdt.c
index cb66c2f99ff1..d0e8203f7a60 100644
--- a/drivers/watchdog/gpio_wdt.c
+++ b/drivers/watchdog/gpio_wdt.c
@@ -156,9 +156,9 @@ static int gpio_wdt_probe(struct platform_device *pdev)
priv->wdd.min_timeout = SOFT_TIMEOUT_MIN;
priv->wdd.max_hw_heartbeat_ms = hw_margin;
priv->wdd.parent = &pdev->dev;
+ priv->wdd.timeout = SOFT_TIMEOUT_DEF;
- if (watchdog_init_timeout(&priv->wdd, 0, &pdev->dev) < 0)
- priv->wdd.timeout = SOFT_TIMEOUT_DEF;
+ watchdog_init_timeout(&priv->wdd, 0, &pdev->dev);
watchdog_stop_on_reboot(&priv->wdd);
--
2.15.1
next prev parent reply other threads:[~2018-02-10 20:36 UTC|newest]
Thread overview: 14+ 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
2018-02-10 20:36 ` [PATCH 2/4] watchdog: omap_wdt: " Marcus Folkesson
2018-02-11 3:54 ` Guenter Roeck
2018-02-10 20:36 ` Marcus Folkesson [this message]
2018-02-11 3:55 ` [PATCH 3/4] watchdog: gpio: " Guenter Roeck
2018-02-10 20:36 ` [PATCH 4/4] watchdog: lpc18xx: remove assignment of unused ret-value Marcus Folkesson
2018-02-10 20:36 ` Marcus Folkesson
2018-02-11 3:56 ` Guenter Roeck
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-11 3:54 ` Guenter Roeck
2018-02-21 1:29 ` Masahiro Yamada
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-3-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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.