summaryrefslogtreecommitdiff
path: root/miscutils/watchdog.c
diff options
context:
space:
mode:
authorDenis Vlasenko2008-10-04 16:40:17 +0000
committerDenis Vlasenko2008-10-04 16:40:17 +0000
commit93d0776a96919a94fca51fe2cfd9530d8c9dcbb9 (patch)
treea9714be0d4c6b22c97c63db94b26e934a0338d06 /miscutils/watchdog.c
parentc2d5a27b622d5a048a3cf175e51f8b4b2b9e9757 (diff)
downloadbusybox-93d0776a96919a94fca51fe2cfd9530d8c9dcbb9.zip
busybox-93d0776a96919a94fca51fe2cfd9530d8c9dcbb9.tar.gz
watchdog: WDIOC_SETTIMEOUT accepts seconds, not milliseconds
klogd: handle many lines at once, by Steve Bennett (steveb AT workware.net.au)
Diffstat (limited to 'miscutils/watchdog.c')
-rw-r--r--miscutils/watchdog.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/miscutils/watchdog.c b/miscutils/watchdog.c
index 9bcd4b8..75a399f 100644
--- a/miscutils/watchdog.c
+++ b/miscutils/watchdog.c
@@ -55,6 +55,8 @@ int watchdog_main(int argc, char **argv)
/* Use known fd # - avoid needing global 'int fd' */
xmove_fd(xopen(argv[argc - 1], O_WRONLY), 3);
+ /* WDIOC_SETTIMEOUT takes seconds, not milliseconds */
+ htimer_duration = htimer_duration / 1000;
ioctl_or_warn(3, WDIOC_SETTIMEOUT, &htimer_duration);
#if 0
ioctl_or_warn(3, WDIOC_GETTIMEOUT, &htimer_duration);