xref: /OK3568_Linux_fs/kernel/Documentation/devicetree/bindings/watchdog/gpio-wdt.txt (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun* GPIO-controlled Watchdog
2*4882a593Smuzhiyun
3*4882a593SmuzhiyunRequired Properties:
4*4882a593Smuzhiyun- compatible: Should contain "linux,wdt-gpio".
5*4882a593Smuzhiyun- gpios: From common gpio binding; gpio connection to WDT reset pin.
6*4882a593Smuzhiyun- hw_algo: The algorithm used by the driver. Should be one of the
7*4882a593Smuzhiyun  following values:
8*4882a593Smuzhiyun  - toggle: Either a high-to-low or a low-to-high transition clears
9*4882a593Smuzhiyun    the WDT counter. The watchdog timer is disabled when GPIO is
10*4882a593Smuzhiyun    left floating or connected to a three-state buffer.
11*4882a593Smuzhiyun  - level: Low or high level starts counting WDT timeout,
12*4882a593Smuzhiyun    the opposite level disables the WDT. Active level is determined
13*4882a593Smuzhiyun    by the GPIO flags.
14*4882a593Smuzhiyun- hw_margin_ms: Maximum time to reset watchdog circuit (milliseconds).
15*4882a593Smuzhiyun
16*4882a593SmuzhiyunOptional Properties:
17*4882a593Smuzhiyun- always-running: If the watchdog timer cannot be disabled, add this flag to
18*4882a593Smuzhiyun  have the driver keep toggling the signal without a client. It will only cease
19*4882a593Smuzhiyun  to toggle the signal when the device is open and the timeout elapsed.
20*4882a593Smuzhiyun
21*4882a593SmuzhiyunExample:
22*4882a593Smuzhiyun	watchdog: watchdog {
23*4882a593Smuzhiyun		/* ADM706 */
24*4882a593Smuzhiyun		compatible = "linux,wdt-gpio";
25*4882a593Smuzhiyun		gpios = <&gpio3 9 GPIO_ACTIVE_LOW>;
26*4882a593Smuzhiyun		hw_algo = "toggle";
27*4882a593Smuzhiyun		hw_margin_ms = <1600>;
28*4882a593Smuzhiyun	};
29