summaryrefslogtreecommitdiff
path: root/com32
diff options
context:
space:
mode:
authorErwan Velu <erwan.velu@zodiacaerospace.com>2012-09-10 17:38:16 +0200
committerErwan Velu <erwanaliasr1@gmail.com>2012-09-10 20:20:43 +0200
commit57d0d1c0030143fde852f459c77a4a0eee7596cf (patch)
treec6b5a5dd3d3c0e7ef189c817a16c1ad9cf482257 /com32
parent0d254b0e4d19cdac49348e34bfda3a358eee47f5 (diff)
downloadsyslinux-57d0d1c0030143fde852f459c77a4a0eee7596cf.tar.gz
kontron_wdt: Enforce timeout value if already set
If the watchdog was already engaged, let's rewrite the timeout to insure the proper value is set.
Diffstat (limited to 'com32')
-rw-r--r--com32/modules/kontron_wdt.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/com32/modules/kontron_wdt.c b/com32/modules/kontron_wdt.c
index 6d21d7c2..4e1d2535 100644
--- a/com32/modules/kontron_wdt.c
+++ b/com32/modules/kontron_wdt.c
@@ -378,6 +378,10 @@ int main(int argc, const char *argv[]) {
status = kempld_read8(&pld, KEMPLD_WDT_CFG);
/* kick the watchdog if it is already enabled, otherwise start it */
if (status & KEMPLD_WDT_CFG_ENABLE) {
+ /* Maybye the BIOS did setup a first timer
+ * in this case, let's enforce the timeout
+ * to be sure we do have the proper value */
+ kempld_wdt_settimeout(&wdt);
kempld_wdt_keepalive(&wdt);
} else {
ret = kempld_wdt_settimeout(&wdt);