All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v4 0/3] watchdog: allow setting deadline for opening /dev/watchdogN
@ 2017-01-09 15:02 Rasmus Villemoes
  2017-01-09 15:02 ` [PATCH v4 1/3] watchdog: introduce watchdog_worker_should_ping helper Rasmus Villemoes
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Rasmus Villemoes @ 2017-01-09 15:02 UTC (permalink / raw)
  To: linux-watchdog, linux-doc, linux-kernel
  Cc: Sylvain Lemieux, Rasmus Villemoes, Guenter Roeck

If a watchdog driver tells the framework that the device is running,
the framework takes care of feeding the watchdog until userspace opens
the device. If the userspace application which is supposed to do that
never comes up properly, the watchdog is fed indefinitely by the
kernel. This can be especially problematic for embedded devices.

These patches allow one to set a maximum time for which the kernel
will feed the watchdog, thus ensuring that either userspace has come
up, or the board gets reset. This allows fallback logic in the
bootloader to attempt some recovery (for example, if an automatic
update is in progress, it could roll back to the previous version).

The patches have been tested on a Raspberry Pi 2 and a Wandboard.

v4 is mostly identical to v1. The differences are that the ability to
compile out this feature is removed, and the ability to set the
default value for the watchdog.open_timeout command line parameter via
Kconfig is split into a separate patch.

Compared to v2/v3, this drops the ability to set the open_timeout via
a device property; I'll leave implementing that to those who actually
need it.

Rasmus Villemoes (3):
  watchdog: introduce watchdog_worker_should_ping helper
  watchdog: introduce watchdog.open_timeout commandline parameter
  watchdog: introduce CONFIG_WATCHDOG_OPEN_TIMEOUT

 Documentation/watchdog/watchdog-parameters.txt | 10 +++++++
 drivers/watchdog/Kconfig                       |  9 +++++++
 drivers/watchdog/watchdog_dev.c                | 37 +++++++++++++++++++++++---
 3 files changed, 52 insertions(+), 4 deletions(-)

-- 
2.7.4

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2017-01-30 10:33 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-09 15:02 [PATCH v4 0/3] watchdog: allow setting deadline for opening /dev/watchdogN Rasmus Villemoes
2017-01-09 15:02 ` [PATCH v4 1/3] watchdog: introduce watchdog_worker_should_ping helper Rasmus Villemoes
2017-01-09 15:02 ` [PATCH v4 2/3] watchdog: introduce watchdog.open_timeout commandline parameter Rasmus Villemoes
2017-01-10 18:08   ` Guenter Roeck
2017-01-11  8:11     ` Rasmus Villemoes
2017-01-11 11:02       ` Guenter Roeck
2017-01-13  9:11         ` Rasmus Villemoes
2017-01-30 10:33           ` Rasmus Villemoes
2017-01-09 15:02 ` [PATCH v4 3/3] watchdog: introduce CONFIG_WATCHDOG_OPEN_TIMEOUT Rasmus Villemoes

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.