xref: /linux/Documentation/devicetree/bindings/watchdog/samsung-wdt.yaml (revision 1623bc27a85a93e82194c8d077eccc464efa67db)
1# SPDX-License-Identifier: GPL-2.0
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/watchdog/samsung-wdt.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: Samsung SoC Watchdog Timer Controller
8
9maintainers:
10  - Krzysztof Kozlowski <krzk@kernel.org>
11
12description: |+
13  The Samsung's Watchdog controller is used for resuming system operation
14  after a preset amount of time during which the WDT reset event has not
15  occurred.
16
17properties:
18  compatible:
19    oneOf:
20      - enum:
21          - google,gs101-wdt                      # for Google gs101
22          - samsung,s3c2410-wdt                   # for S3C2410
23          - samsung,s3c6410-wdt                   # for S3C6410, S5PV210 and Exynos4
24          - samsung,exynos5250-wdt                # for Exynos5250
25          - samsung,exynos5420-wdt                # for Exynos5420
26          - samsung,exynos7-wdt                   # for Exynos7
27          - samsung,exynos850-wdt                 # for Exynos850
28          - samsung,exynosautov9-wdt              # for Exynosautov9
29          - samsung,exynosautov920-wdt            # for Exynosautov920
30      - items:
31          - enum:
32              - tesla,fsd-wdt
33          - const: samsung,exynos7-wdt
34
35  reg:
36    maxItems: 1
37
38  clocks:
39    minItems: 1
40    maxItems: 2
41
42  clock-names:
43    minItems: 1
44    maxItems: 2
45
46  interrupts:
47    maxItems: 1
48
49  samsung,cluster-index:
50    $ref: /schemas/types.yaml#/definitions/uint32
51    description:
52      Index of CPU cluster on which watchdog is running (in case of Exynos850
53      or Google gs101).
54
55  samsung,syscon-phandle:
56    $ref: /schemas/types.yaml#/definitions/phandle
57    description:
58      Phandle to the PMU system controller node (in case of Exynos5250,
59      Exynos5420, Exynos7, Exynos850 and gs101).
60
61required:
62  - compatible
63  - clocks
64  - clock-names
65  - interrupts
66  - reg
67
68allOf:
69  - $ref: watchdog.yaml#
70  - if:
71      properties:
72        compatible:
73          contains:
74            enum:
75              - google,gs101-wdt
76              - samsung,exynos5250-wdt
77              - samsung,exynos5420-wdt
78              - samsung,exynos7-wdt
79              - samsung,exynos850-wdt
80              - samsung,exynosautov9-wdt
81              - samsung,exynosautov920-wdt
82    then:
83      required:
84        - samsung,syscon-phandle
85  - if:
86      properties:
87        compatible:
88          contains:
89            enum:
90              - google,gs101-wdt
91              - samsung,exynos850-wdt
92              - samsung,exynosautov9-wdt
93              - samsung,exynosautov920-wdt
94    then:
95      properties:
96        clocks:
97          items:
98            - description: Bus clock, used for register interface
99            - description: Source clock (driving watchdog counter)
100        clock-names:
101          items:
102            - const: watchdog
103            - const: watchdog_src
104        samsung,cluster-index:
105          enum: [0, 1]
106      required:
107        - samsung,cluster-index
108    else:
109      properties:
110        clocks:
111          items:
112            - description: Bus clock, which is also a source clock
113        clock-names:
114          items:
115            - const: watchdog
116        samsung,cluster-index: false
117
118unevaluatedProperties: false
119
120examples:
121  - |
122    watchdog@101d0000 {
123        compatible = "samsung,exynos5250-wdt";
124        reg = <0x101D0000 0x100>;
125        interrupts = <0 42 0>;
126        clocks = <&clock 336>;
127        clock-names = "watchdog";
128        samsung,syscon-phandle = <&pmu_syscon>;
129    };
130