Skip to content

Commit ae6ee2f

Browse files
James HoganWim Van Sebroeck
authored andcommitted
watchdog: imgpdc: Fix default heartbeat
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: 9393766 ("watchdog: ImgTec PDC Watchdog Timer Driver") Signed-off-by: James Hogan <james.hogan@imgtec.com> 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 Reviewed-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
1 parent a629c08 commit ae6ee2f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

drivers/watchdog/imgpdc_wdt.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,10 @@
4242
#define PDC_WDT_MIN_TIMEOUT 1
4343
#define PDC_WDT_DEF_TIMEOUT 64
4444

45-
static int heartbeat;
45+
static int heartbeat = PDC_WDT_DEF_TIMEOUT;
4646
module_param(heartbeat, int, 0);
47-
MODULE_PARM_DESC(heartbeat, "Watchdog heartbeats in seconds. "
48-
"(default = " __MODULE_STRING(PDC_WDT_DEF_TIMEOUT) ")");
47+
MODULE_PARM_DESC(heartbeat, "Watchdog heartbeats in seconds "
48+
"(default=" __MODULE_STRING(PDC_WDT_DEF_TIMEOUT) ")");
4949

5050
static bool nowayout = WATCHDOG_NOWAYOUT;
5151
module_param(nowayout, bool, 0);

0 commit comments

Comments
 (0)