GPIO-controlled Watchdog
Schema identifier ($id): "http://devicetree.org/schemas/watchdog/linux,wdt-gpio.yaml#"
Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"
Maintainers (maintainers): "Guenter Roeck <linux@roeck-us.net>", "Robert Marko <robert.marko@sartura.hr>"
Properties and child nodes (properties) #
compatible — required here #
Exact value (const): "linux,wdt-gpio"
gpios — required here #
gpio connection to WDT reset pin
Maximum number of items (maxItems): 1
hw_algo — required here #
The algorithm used by the driver.
Exactly one of these rules must match (oneOf) #
Rule 1
Either a high-to-low or a low-to-high transition clears the WDT counter. The watchdog timer is disabled when GPIO is left floating or connected to a three-state buffer.
Exact value (
const):"toggle"
Rule 2
Low or high level starts counting WDT timeout, the opposite level disables the WDT. Active level is determined by the GPIO flags.
Exact value (
const):"level"
hw_margin_ms — required here #
Maximum time to reset watchdog circuit (milliseconds).
Shared schema rule ($ref): /schemas/types.yaml#/definitions/uint32
Minimum value (minimum): 2
Maximum value (maximum): 65535
always-running — not listed as required here #
Value type (type): "boolean"
If the watchdog timer cannot be disabled, add this flag to have the driver keep toggling the signal without a client. It will only cease to toggle the signal when the device is open and the timeout elapsed.
Required in this object (required): "compatible", "gpios", "hw_algo", "hw_margin_ms"
All of these rules must match (allOf) #
Rule 1 #
Shared schema rule (
$ref):watchdog.yaml#
Properties not evaluated by applicable rules (unevaluatedProperties) #
false
Not allowed by this rule.
Examples (examples) #
#include <dt-bindings/gpio/gpio.h>
watchdog {
compatible = "linux,wdt-gpio";
gpios = <&gpio3 9 GPIO_ACTIVE_LOW>;
hw_algo = "toggle";
hw_margin_ms = <1600>;
};
Source notes #
Annotations retained from the schema source
Line 1: SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)