1bd9eccf1SNeil Armstrong# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
2bd9eccf1SNeil Armstrong# Copyright 2019 BayLibre, SAS
3bd9eccf1SNeil Armstrong%YAML 1.2
4bd9eccf1SNeil Armstrong---
5bd9eccf1SNeil Armstrong$id: "http://devicetree.org/schemas/power/amlogic,meson-ee-pwrc.yaml#"
6bd9eccf1SNeil Armstrong$schema: "http://devicetree.org/meta-schemas/core.yaml#"
7bd9eccf1SNeil Armstrong
8bd9eccf1SNeil Armstrongtitle: Amlogic Meson Everything-Else Power Domains
9bd9eccf1SNeil Armstrong
10bd9eccf1SNeil Armstrongmaintainers:
11bd9eccf1SNeil Armstrong  - Neil Armstrong <narmstrong@baylibre.com>
12bd9eccf1SNeil Armstrong
13bd9eccf1SNeil Armstrongdescription: |+
14bd9eccf1SNeil Armstrong  The Everything-Else Power Domains node should be the child of a syscon
15bd9eccf1SNeil Armstrong  node with the required property:
16bd9eccf1SNeil Armstrong
17bd9eccf1SNeil Armstrong  - compatible: Should be the following:
18bd9eccf1SNeil Armstrong                "amlogic,meson-gx-hhi-sysctrl", "simple-mfd", "syscon"
19bd9eccf1SNeil Armstrong
20bd9eccf1SNeil Armstrong  Refer to the the bindings described in
2154b3719dSMauro Carvalho Chehab  Documentation/devicetree/bindings/mfd/syscon.yaml
22bd9eccf1SNeil Armstrong
23bd9eccf1SNeil Armstrongproperties:
24bd9eccf1SNeil Armstrong  compatible:
25bd9eccf1SNeil Armstrong    enum:
2618dfc0bfSMartin Blumenstingl      - amlogic,meson8-pwrc
2718dfc0bfSMartin Blumenstingl      - amlogic,meson8b-pwrc
2818dfc0bfSMartin Blumenstingl      - amlogic,meson8m2-pwrc
29cc9ca02aSMartin Blumenstingl      - amlogic,meson-gxbb-pwrc
30bd9eccf1SNeil Armstrong      - amlogic,meson-g12a-pwrc
31bd9eccf1SNeil Armstrong      - amlogic,meson-sm1-pwrc
32bd9eccf1SNeil Armstrong
33bd9eccf1SNeil Armstrong  clocks:
3418dfc0bfSMartin Blumenstingl    minItems: 1
3518dfc0bfSMartin Blumenstingl    maxItems: 2
36bd9eccf1SNeil Armstrong
37bd9eccf1SNeil Armstrong  clock-names:
3818dfc0bfSMartin Blumenstingl    minItems: 1
3918dfc0bfSMartin Blumenstingl    maxItems: 2
40bd9eccf1SNeil Armstrong    items:
41bd9eccf1SNeil Armstrong      - const: vpu
42bd9eccf1SNeil Armstrong      - const: vapb
43bd9eccf1SNeil Armstrong
44bd9eccf1SNeil Armstrong  resets:
45bd9eccf1SNeil Armstrong    minItems: 11
46cc9ca02aSMartin Blumenstingl    maxItems: 12
47bd9eccf1SNeil Armstrong
48bd9eccf1SNeil Armstrong  reset-names:
4918dfc0bfSMartin Blumenstingl    minItems: 11
50cc9ca02aSMartin Blumenstingl    maxItems: 12
5118dfc0bfSMartin Blumenstingl
5218dfc0bfSMartin Blumenstingl  "#power-domain-cells":
5318dfc0bfSMartin Blumenstingl    const: 1
5418dfc0bfSMartin Blumenstingl
5518dfc0bfSMartin Blumenstingl  amlogic,ao-sysctrl:
5618dfc0bfSMartin Blumenstingl    description: phandle to the AO sysctrl node
57571d54edSLinus Torvalds    $ref: /schemas/types.yaml#/definitions/phandle
5818dfc0bfSMartin Blumenstingl
5918dfc0bfSMartin BlumenstinglallOf:
6018dfc0bfSMartin Blumenstingl  - if:
6118dfc0bfSMartin Blumenstingl      properties:
6218dfc0bfSMartin Blumenstingl        compatible:
6318dfc0bfSMartin Blumenstingl          enum:
6418dfc0bfSMartin Blumenstingl            - amlogic,meson8b-pwrc
6518dfc0bfSMartin Blumenstingl            - amlogic,meson8m2-pwrc
6618dfc0bfSMartin Blumenstingl    then:
6718dfc0bfSMartin Blumenstingl      properties:
6818dfc0bfSMartin Blumenstingl        reset-names:
6918dfc0bfSMartin Blumenstingl          items:
7018dfc0bfSMartin Blumenstingl            - const: dblk
7118dfc0bfSMartin Blumenstingl            - const: pic_dc
7218dfc0bfSMartin Blumenstingl            - const: hdmi_apb
7318dfc0bfSMartin Blumenstingl            - const: hdmi_system
7418dfc0bfSMartin Blumenstingl            - const: venci
7518dfc0bfSMartin Blumenstingl            - const: vencp
7618dfc0bfSMartin Blumenstingl            - const: vdac
7718dfc0bfSMartin Blumenstingl            - const: vencl
7818dfc0bfSMartin Blumenstingl            - const: viu
7918dfc0bfSMartin Blumenstingl            - const: venc
8018dfc0bfSMartin Blumenstingl            - const: rdma
8118dfc0bfSMartin Blumenstingl      required:
8218dfc0bfSMartin Blumenstingl        - resets
8318dfc0bfSMartin Blumenstingl        - reset-names
8418dfc0bfSMartin Blumenstingl
8518dfc0bfSMartin Blumenstingl  - if:
8618dfc0bfSMartin Blumenstingl      properties:
8718dfc0bfSMartin Blumenstingl        compatible:
8818dfc0bfSMartin Blumenstingl          enum:
89cc9ca02aSMartin Blumenstingl            - amlogic,meson-gxbb-pwrc
90cc9ca02aSMartin Blumenstingl    then:
91cc9ca02aSMartin Blumenstingl      properties:
92cc9ca02aSMartin Blumenstingl        reset-names:
93cc9ca02aSMartin Blumenstingl          items:
94cc9ca02aSMartin Blumenstingl            - const: viu
95cc9ca02aSMartin Blumenstingl            - const: venc
96cc9ca02aSMartin Blumenstingl            - const: vcbus
97cc9ca02aSMartin Blumenstingl            - const: bt656
98cc9ca02aSMartin Blumenstingl            - const: dvin
99cc9ca02aSMartin Blumenstingl            - const: rdma
100cc9ca02aSMartin Blumenstingl            - const: venci
101cc9ca02aSMartin Blumenstingl            - const: vencp
102cc9ca02aSMartin Blumenstingl            - const: vdac
103cc9ca02aSMartin Blumenstingl            - const: vdi6
104cc9ca02aSMartin Blumenstingl            - const: vencl
105cc9ca02aSMartin Blumenstingl            - const: vid_lock
106cc9ca02aSMartin Blumenstingl      required:
107cc9ca02aSMartin Blumenstingl        - resets
108cc9ca02aSMartin Blumenstingl        - reset-names
109cc9ca02aSMartin Blumenstingl
110cc9ca02aSMartin Blumenstingl  - if:
111cc9ca02aSMartin Blumenstingl      properties:
112cc9ca02aSMartin Blumenstingl        compatible:
113cc9ca02aSMartin Blumenstingl          enum:
11418dfc0bfSMartin Blumenstingl            - amlogic,meson-g12a-pwrc
11518dfc0bfSMartin Blumenstingl            - amlogic,meson-sm1-pwrc
11618dfc0bfSMartin Blumenstingl    then:
11718dfc0bfSMartin Blumenstingl      properties:
11818dfc0bfSMartin Blumenstingl        reset-names:
119bd9eccf1SNeil Armstrong          items:
120bd9eccf1SNeil Armstrong            - const: viu
121bd9eccf1SNeil Armstrong            - const: venc
122bd9eccf1SNeil Armstrong            - const: vcbus
123bd9eccf1SNeil Armstrong            - const: bt656
124bd9eccf1SNeil Armstrong            - const: rdma
125bd9eccf1SNeil Armstrong            - const: venci
126bd9eccf1SNeil Armstrong            - const: vencp
127bd9eccf1SNeil Armstrong            - const: vdac
128bd9eccf1SNeil Armstrong            - const: vdi6
129bd9eccf1SNeil Armstrong            - const: vencl
130bd9eccf1SNeil Armstrong            - const: vid_lock
13118dfc0bfSMartin Blumenstingl      required:
13218dfc0bfSMartin Blumenstingl        - resets
13318dfc0bfSMartin Blumenstingl        - reset-names
134bd9eccf1SNeil Armstrong
135bd9eccf1SNeil Armstrongrequired:
136bd9eccf1SNeil Armstrong  - compatible
137bd9eccf1SNeil Armstrong  - clocks
138bd9eccf1SNeil Armstrong  - clock-names
139bd9eccf1SNeil Armstrong  - "#power-domain-cells"
140bd9eccf1SNeil Armstrong  - amlogic,ao-sysctrl
141bd9eccf1SNeil Armstrong
1427f464532SRob HerringadditionalProperties: false
1437f464532SRob Herring
144bd9eccf1SNeil Armstrongexamples:
145bd9eccf1SNeil Armstrong  - |
146bd9eccf1SNeil Armstrong    pwrc: power-controller {
147bd9eccf1SNeil Armstrong          compatible = "amlogic,meson-sm1-pwrc";
148bd9eccf1SNeil Armstrong          #power-domain-cells = <1>;
149bd9eccf1SNeil Armstrong          amlogic,ao-sysctrl = <&rti>;
150bd9eccf1SNeil Armstrong          resets = <&reset_viu>,
151bd9eccf1SNeil Armstrong                   <&reset_venc>,
152bd9eccf1SNeil Armstrong                   <&reset_vcbus>,
153bd9eccf1SNeil Armstrong                   <&reset_bt656>,
154bd9eccf1SNeil Armstrong                   <&reset_rdma>,
155bd9eccf1SNeil Armstrong                   <&reset_venci>,
156bd9eccf1SNeil Armstrong                   <&reset_vencp>,
157bd9eccf1SNeil Armstrong                   <&reset_vdac>,
158bd9eccf1SNeil Armstrong                   <&reset_vdi6>,
159bd9eccf1SNeil Armstrong                   <&reset_vencl>,
160bd9eccf1SNeil Armstrong                   <&reset_vid_lock>;
161bd9eccf1SNeil Armstrong          reset-names = "viu", "venc", "vcbus", "bt656",
162bd9eccf1SNeil Armstrong                        "rdma", "venci", "vencp", "vdac",
163bd9eccf1SNeil Armstrong                        "vdi6", "vencl", "vid_lock";
164bd9eccf1SNeil Armstrong          clocks = <&clk_vpu>, <&clk_vapb>;
165bd9eccf1SNeil Armstrong          clock-names = "vpu", "vapb";
166bd9eccf1SNeil Armstrong    };
167