From: James Hogan <james.hogan@imgtec.com>
To: Wim Van Sebroeck <wim@iguana.be>, linux-watchdog@vger.kernel.org
Cc: James Hogan <james@albanarts.com>,
James Hogan <james.hogan@imgtec.com>,
Ezequiel Garcia <ezequiel.garcia@imgtec.com>,
Naidu Tellapati <Naidu.Tellapati@imgtec.com>,
Jude Abraham <Jude.Abraham@imgtec.com>
Subject: [PATCH 2/2] watchdog: imgpdc: Fix default heartbeat
Date: Fri, 20 Feb 2015 23:45:45 +0000 [thread overview]
Message-ID: <1424475945-30009-3-git-send-email-james.hogan@imgtec.com> (raw)
In-Reply-To: <1424475945-30009-1-git-send-email-james.hogan@imgtec.com>
The IMG PDC watchdog driver heartbeat module parameter has no default so
it is initialised to zero. This results in the following warning during
probe:
imgpdc-wdt 2006000.wdt: Initial timeout out of range! setting max timeout
The module parameter description implies that the default value should
be PDC_WDT_DEF_TIMEOUT, which isn't yet used, so initialise it to that.
Also tweak the heartbeat module parameter description for consistency.
Fixes: 93937669e9b5 ("watchdog: ImgTec PDC Watchdog Timer Driver")
Signed-off-by: James Hogan <james.hogan@imgtec.com>
Cc: Wim Van Sebroeck <wim@iguana.be>
Cc: Ezequiel Garcia <ezequiel.garcia@imgtec.com>
Cc: Naidu Tellapati <Naidu.Tellapati@imgtec.com>
Cc: Jude Abraham <Jude.Abraham@imgtec.com>
Cc: linux-watchdog@vger.kernel.org
---
drivers/watchdog/imgpdc_wdt.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/watchdog/imgpdc_wdt.c b/drivers/watchdog/imgpdc_wdt.c
index 32c35eb..0deaa4f 100644
--- a/drivers/watchdog/imgpdc_wdt.c
+++ b/drivers/watchdog/imgpdc_wdt.c
@@ -42,10 +42,10 @@
#define PDC_WDT_MIN_TIMEOUT 1
#define PDC_WDT_DEF_TIMEOUT 64
-static int heartbeat;
+static int heartbeat = PDC_WDT_DEF_TIMEOUT;
module_param(heartbeat, int, 0);
-MODULE_PARM_DESC(heartbeat, "Watchdog heartbeats in seconds. "
- "(default = " __MODULE_STRING(PDC_WDT_DEF_TIMEOUT) ")");
+MODULE_PARM_DESC(heartbeat, "Watchdog heartbeats in seconds "
+ "(default=" __MODULE_STRING(PDC_WDT_DEF_TIMEOUT) ")");
static bool nowayout = WATCHDOG_NOWAYOUT;
module_param(nowayout, bool, 0);
--
2.0.5
next prev parent reply other threads:[~2015-02-20 23:45 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-20 23:45 [PATCH 0/2] watchdog: imgpdc: Runtime fixes James Hogan
2015-02-20 23:45 ` [PATCH 1/2] watchdog: imgpdc: Fix probe NULL pointer dereference James Hogan
2015-02-23 19:26 ` Guenter Roeck
2015-02-20 23:45 ` James Hogan [this message]
2015-02-23 19:27 ` [PATCH 2/2] watchdog: imgpdc: Fix default heartbeat Guenter Roeck
2015-03-20 20:53 ` [PATCH 0/2] watchdog: imgpdc: Runtime fixes James Hogan
2015-03-22 17:06 ` Guenter Roeck
2015-03-24 7:42 ` Wim Van Sebroeck
2015-03-24 8:19 ` Wim Van Sebroeck
2015-03-24 8:47 ` Naidu Tellapati
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=1424475945-30009-3-git-send-email-james.hogan@imgtec.com \
--to=james.hogan@imgtec.com \
--cc=Jude.Abraham@imgtec.com \
--cc=Naidu.Tellapati@imgtec.com \
--cc=ezequiel.garcia@imgtec.com \
--cc=james@albanarts.com \
--cc=linux-watchdog@vger.kernel.org \
--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