From 4f4d086275ebad32a17dbb54ece0d0dfdec082db Mon Sep 17 00:00:00 2001 From: Andrew Dyer Date: Tue, 8 Jan 2008 14:40:37 -0600 Subject: [PATCH] --- yaml --- r: 75551 b: refs/heads/master c: 0d710cba3afde2109030254ee90654fbb580e8af h: refs/heads/master i: 75549: 3ab1e7ac4733af8050898e34cdd9e6edc1ecffdd 75547: cef7087ee8149452eeddeab02af1cea1b1bccf33 75543: d8395ebe96956b8101d659c1260fa603ba6288bf 75535: 74d44091557b5b7b1998b63bcf9d4fcecad1495b 75519: b8e1b9d14d6275e6a1db501b88abc908d192d415 v: v3 --- [refs] | 2 +- trunk/Documentation/watchdog/watchdog-api.txt | 38 ++++++++++--------- 2 files changed, 22 insertions(+), 18 deletions(-) diff --git a/[refs] b/[refs] index 54edda166fe6..eea8c9cb5ed2 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: cde10ba3ba439592d1bc094102ebfccdeee80cf9 +refs/heads/master: 0d710cba3afde2109030254ee90654fbb580e8af diff --git a/trunk/Documentation/watchdog/watchdog-api.txt b/trunk/Documentation/watchdog/watchdog-api.txt index bb7cb1d31ec7..4cc4ba9d7150 100644 --- a/trunk/Documentation/watchdog/watchdog-api.txt +++ b/trunk/Documentation/watchdog/watchdog-api.txt @@ -42,23 +42,27 @@ like this source file: see Documentation/watchdog/src/watchdog-simple.c A more advanced driver could for example check that a HTTP server is still responding before doing the write call to ping the watchdog. -When the device is closed, the watchdog is disabled. This is not -always such a good idea, since if there is a bug in the watchdog -daemon and it crashes the system will not reboot. Because of this, -some of the drivers support the configuration option "Disable watchdog -shutdown on close", CONFIG_WATCHDOG_NOWAYOUT. If it is set to Y when -compiling the kernel, there is no way of disabling the watchdog once -it has been started. So, if the watchdog daemon crashes, the system -will reboot after the timeout has passed. Watchdog devices also usually -support the nowayout module parameter so that this option can be controlled -at runtime. - -Drivers will not disable the watchdog, unless a specific magic character 'V' -has been sent /dev/watchdog just before closing the file. If the userspace -daemon closes the file without sending this special character, the driver -will assume that the daemon (and userspace in general) died, and will stop -pinging the watchdog without disabling it first. This will then cause a -reboot if the watchdog is not re-opened in sufficient time. +When the device is closed, the watchdog is disabled, unless the "Magic +Close" feature is supported (see below). This is not always such a +good idea, since if there is a bug in the watchdog daemon and it +crashes the system will not reboot. Because of this, some of the +drivers support the configuration option "Disable watchdog shutdown on +close", CONFIG_WATCHDOG_NOWAYOUT. If it is set to Y when compiling +the kernel, there is no way of disabling the watchdog once it has been +started. So, if the watchdog daemon crashes, the system will reboot +after the timeout has passed. Watchdog devices also usually support +the nowayout module parameter so that this option can be controlled at +runtime. + +Magic Close feature: + +If a driver supports "Magic Close", the driver will not disable the +watchdog unless a specific magic character 'V' has been sent to +/dev/watchdog just before closing the file. If the userspace daemon +closes the file without sending this special character, the driver +will assume that the daemon (and userspace in general) died, and will +stop pinging the watchdog without disabling it first. This will then +cause a reboot if the watchdog is not re-opened in sufficient time. The ioctl API: