Merge tag 'arm-dt-5.8' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc
[linux-2.6-microblaze.git] / Documentation / devicetree / bindings / power / amlogic,meson-ee-pwrc.yaml
1 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
2 # Copyright 2019 BayLibre, SAS
3 %YAML 1.2
4 ---
5 $id: "http://devicetree.org/schemas/power/amlogic,meson-ee-pwrc.yaml#"
6 $schema: "http://devicetree.org/meta-schemas/core.yaml#"
7
8 title: Amlogic Meson Everything-Else Power Domains
9
10 maintainers:
11   - Neil Armstrong <narmstrong@baylibre.com>
12
13 description: |+
14   The Everything-Else Power Domains node should be the child of a syscon
15   node with the required property:
16
17   - compatible: Should be the following:
18                 "amlogic,meson-gx-hhi-sysctrl", "simple-mfd", "syscon"
19
20   Refer to the the bindings described in
21   Documentation/devicetree/bindings/mfd/syscon.yaml
22
23 properties:
24   compatible:
25     enum:
26       - amlogic,meson8-pwrc
27       - amlogic,meson8b-pwrc
28       - amlogic,meson8m2-pwrc
29       - amlogic,meson-gxbb-pwrc
30       - amlogic,meson-g12a-pwrc
31       - amlogic,meson-sm1-pwrc
32
33   clocks:
34     minItems: 1
35     maxItems: 2
36
37   clock-names:
38     minItems: 1
39     maxItems: 2
40     items:
41       - const: vpu
42       - const: vapb
43
44   resets:
45     minItems: 11
46     maxItems: 12
47
48   reset-names:
49     minItems: 11
50     maxItems: 12
51
52   "#power-domain-cells":
53     const: 1
54
55   amlogic,ao-sysctrl:
56     description: phandle to the AO sysctrl node
57     allOf:
58       - $ref: /schemas/types.yaml#/definitions/phandle
59
60 allOf:
61   - if:
62       properties:
63         compatible:
64           enum:
65             - amlogic,meson8b-pwrc
66             - amlogic,meson8m2-pwrc
67     then:
68       properties:
69         reset-names:
70           items:
71             - const: dblk
72             - const: pic_dc
73             - const: hdmi_apb
74             - const: hdmi_system
75             - const: venci
76             - const: vencp
77             - const: vdac
78             - const: vencl
79             - const: viu
80             - const: venc
81             - const: rdma
82       required:
83         - resets
84         - reset-names
85
86   - if:
87       properties:
88         compatible:
89           enum:
90             - amlogic,meson-gxbb-pwrc
91     then:
92       properties:
93         reset-names:
94           items:
95             - const: viu
96             - const: venc
97             - const: vcbus
98             - const: bt656
99             - const: dvin
100             - const: rdma
101             - const: venci
102             - const: vencp
103             - const: vdac
104             - const: vdi6
105             - const: vencl
106             - const: vid_lock
107       required:
108         - resets
109         - reset-names
110
111   - if:
112       properties:
113         compatible:
114           enum:
115             - amlogic,meson-g12a-pwrc
116             - amlogic,meson-sm1-pwrc
117     then:
118       properties:
119         reset-names:
120           items:
121             - const: viu
122             - const: venc
123             - const: vcbus
124             - const: bt656
125             - const: rdma
126             - const: venci
127             - const: vencp
128             - const: vdac
129             - const: vdi6
130             - const: vencl
131             - const: vid_lock
132       required:
133         - resets
134         - reset-names
135
136 required:
137   - compatible
138   - clocks
139   - clock-names
140   - "#power-domain-cells"
141   - amlogic,ao-sysctrl
142
143 additionalProperties: false
144
145 examples:
146   - |
147     pwrc: power-controller {
148           compatible = "amlogic,meson-sm1-pwrc";
149           #power-domain-cells = <1>;
150           amlogic,ao-sysctrl = <&rti>;
151           resets = <&reset_viu>,
152                    <&reset_venc>,
153                    <&reset_vcbus>,
154                    <&reset_bt656>,
155                    <&reset_rdma>,
156                    <&reset_venci>,
157                    <&reset_vencp>,
158                    <&reset_vdac>,
159                    <&reset_vdi6>,
160                    <&reset_vencl>,
161                    <&reset_vid_lock>;
162           reset-names = "viu", "venc", "vcbus", "bt656",
163                         "rdma", "venci", "vencp", "vdac",
164                         "vdi6", "vencl", "vid_lock";
165           clocks = <&clk_vpu>, <&clk_vapb>;
166           clock-names = "vpu", "vapb";
167     };