128 lines · yaml
1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)2# Copyright (C) 2022 Microchip Technology, Inc. and its subsidiaries3%YAML 1.24---5$id: http://devicetree.org/schemas/watchdog/atmel,at91sam9-wdt.yaml#6$schema: http://devicetree.org/meta-schemas/core.yaml#7 8title: Atmel Watchdog Timers9 10maintainers:11 - Eugen Hristev <eugen.hristev@microchip.com>12 13properties:14 compatible:15 const: atmel,at91sam9260-wdt16 17 reg:18 maxItems: 119 20 clocks:21 maxItems: 122 23 interrupts:24 maxItems: 125 26 atmel,max-heartbeat-sec:27 description:28 Should contain the maximum heartbeat value in seconds. This value29 should be less or equal to 16. It is used to compute the WDV field.30 maximum: 1631 32 atmel,min-heartbeat-sec:33 description:34 Should contain the minimum heartbeat value in seconds. This value35 must be smaller than the max-heartbeat-sec value. It is used to36 compute the WDD field.37 maximum: 1638 39 atmel,watchdog-type:40 $ref: /schemas/types.yaml#/definitions/string41 description: |42 Should be hardware or software.43 oneOf:44 - description:45 Hardware watchdog uses the at91 watchdog reset.46 const: hardware47 - description: |48 Software watchdog uses the watchdog interrupt49 to trigger a software reset.50 const: software51 default: hardware52 53 atmel,reset-type:54 $ref: /schemas/types.yaml#/definitions/string55 description: |56 Should be proc or all. This is valid only when using hardware watchdog.57 oneOf:58 - description:59 Assert peripherals and processor reset signals.60 const: all61 - description:62 Assert the processor reset signal.63 const: proc64 default: all65 66 atmel,disable:67 $ref: /schemas/types.yaml#/definitions/flag68 description:69 Should be present if you want to stop the watchdog.70 71 atmel,idle-halt:72 $ref: /schemas/types.yaml#/definitions/flag73 description: |74 Should be present if you want to stop the watchdog when75 entering idle state.76 CAUTION: This property should be used with care, it actually makes the77 watchdog not counting when the CPU is in idle state, therefore the78 watchdog reset time depends on mean CPU usage and will not reset at all79 if the CPU stops working while it is in idle state, which is probably80 not what you want.81 82 atmel,dbg-halt:83 $ref: /schemas/types.yaml#/definitions/flag84 description: |85 Should be present if you want to stop the watchdog when86 entering debug state.87 88required:89 - compatible90 - reg91 - clocks92 93allOf:94 - $ref: watchdog.yaml#95 - if:96 properties:97 atmel,reset-type:98 enum:99 - all100 - proc101 then:102 properties:103 atmel,watchdog-type:104 const: hardware105 106dependencies:107 atmel,reset-type: ['atmel,watchdog-type']108 109unevaluatedProperties: false110 111examples:112 - |113 #include <dt-bindings/interrupt-controller/irq.h>114 115 watchdog@fffffd40 {116 compatible = "atmel,at91sam9260-wdt";117 reg = <0xfffffd40 0x10>;118 interrupts = <1 IRQ_TYPE_LEVEL_HIGH 7>;119 clocks = <&clk32k>;120 timeout-sec = <15>;121 atmel,watchdog-type = "hardware";122 atmel,reset-type = "all";123 atmel,dbg-halt;124 atmel,idle-halt;125 atmel,max-heartbeat-sec = <16>;126 atmel,min-heartbeat-sec = <0>;127 };128