xref: /freebsd/sys/contrib/device-tree/Bindings/power/fsl,imx-gpc.yaml (revision 7ef62cebc2f965b0f640263e179276928885e33d)
1c66ec88fSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2c66ec88fSEmmanuel Vadot%YAML 1.2
3c66ec88fSEmmanuel Vadot---
4c66ec88fSEmmanuel Vadot$id: http://devicetree.org/schemas/power/fsl,imx-gpc.yaml#
5c66ec88fSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6c66ec88fSEmmanuel Vadot
7c66ec88fSEmmanuel Vadottitle: Freescale i.MX General Power Controller
8c66ec88fSEmmanuel Vadot
9c66ec88fSEmmanuel Vadotmaintainers:
10c66ec88fSEmmanuel Vadot  - Philipp Zabel <p.zabel@pengutronix.de>
11c66ec88fSEmmanuel Vadot
12c66ec88fSEmmanuel Vadotdescription: |
13c66ec88fSEmmanuel Vadot  The i.MX6 General Power Control (GPC) block contains DVFS load tracking
14c66ec88fSEmmanuel Vadot  counters and Power Gating Control (PGC).
15c66ec88fSEmmanuel Vadot
16c66ec88fSEmmanuel Vadot  The power domains are generic power domain providers as documented in
17c66ec88fSEmmanuel Vadot  Documentation/devicetree/bindings/power/power-domain.yaml. They are
18c66ec88fSEmmanuel Vadot  described as subnodes of the power gating controller 'pgc' node of the GPC.
19c66ec88fSEmmanuel Vadot
20c66ec88fSEmmanuel Vadot  IP cores belonging to a power domain should contain a 'power-domains'
21c66ec88fSEmmanuel Vadot  property that is a phandle pointing to the power domain the device belongs
22c66ec88fSEmmanuel Vadot  to.
23c66ec88fSEmmanuel Vadot
24c66ec88fSEmmanuel Vadotproperties:
25c66ec88fSEmmanuel Vadot  compatible:
26c66ec88fSEmmanuel Vadot    enum:
27c66ec88fSEmmanuel Vadot      - fsl,imx6q-gpc
28c66ec88fSEmmanuel Vadot      - fsl,imx6qp-gpc
29c66ec88fSEmmanuel Vadot      - fsl,imx6sl-gpc
30c66ec88fSEmmanuel Vadot      - fsl,imx6sx-gpc
31c66ec88fSEmmanuel Vadot
32c66ec88fSEmmanuel Vadot  reg:
33c66ec88fSEmmanuel Vadot    maxItems: 1
34c66ec88fSEmmanuel Vadot
35c66ec88fSEmmanuel Vadot  interrupts:
36c66ec88fSEmmanuel Vadot    maxItems: 1
37c66ec88fSEmmanuel Vadot
38c66ec88fSEmmanuel Vadot  clocks:
39c66ec88fSEmmanuel Vadot    maxItems: 1
40c66ec88fSEmmanuel Vadot
41c66ec88fSEmmanuel Vadot  clock-names:
42c66ec88fSEmmanuel Vadot    const: ipg
43c66ec88fSEmmanuel Vadot
44c66ec88fSEmmanuel Vadot  pgc:
45c66ec88fSEmmanuel Vadot    type: object
46*7ef62cebSEmmanuel Vadot    additionalProperties: false
47c66ec88fSEmmanuel Vadot    description: list of power domains provided by this controller.
48c66ec88fSEmmanuel Vadot
49*7ef62cebSEmmanuel Vadot    properties:
50*7ef62cebSEmmanuel Vadot      '#address-cells':
51*7ef62cebSEmmanuel Vadot        const: 1
52*7ef62cebSEmmanuel Vadot
53*7ef62cebSEmmanuel Vadot      '#size-cells':
54*7ef62cebSEmmanuel Vadot        const: 0
55*7ef62cebSEmmanuel Vadot
56c66ec88fSEmmanuel Vadot    patternProperties:
57c66ec88fSEmmanuel Vadot      "power-domain@[0-9]$":
58c66ec88fSEmmanuel Vadot        type: object
59*7ef62cebSEmmanuel Vadot        additionalProperties: false
60*7ef62cebSEmmanuel Vadot
61c66ec88fSEmmanuel Vadot        properties:
62c66ec88fSEmmanuel Vadot
63c66ec88fSEmmanuel Vadot          '#power-domain-cells':
64c66ec88fSEmmanuel Vadot            const: 0
65c66ec88fSEmmanuel Vadot
66c66ec88fSEmmanuel Vadot          reg:
67c66ec88fSEmmanuel Vadot            description: |
68c66ec88fSEmmanuel Vadot              The following DOMAIN_INDEX values are valid for i.MX6Q:
69c66ec88fSEmmanuel Vadot                ARM_DOMAIN     0
70c66ec88fSEmmanuel Vadot                PU_DOMAIN      1
71c66ec88fSEmmanuel Vadot              The following additional DOMAIN_INDEX value is valid for i.MX6SL:
72c66ec88fSEmmanuel Vadot                DISPLAY_DOMAIN 2
73c66ec88fSEmmanuel Vadot              The following additional DOMAIN_INDEX value is valid for i.MX6SX:
74c66ec88fSEmmanuel Vadot                PCI_DOMAIN     3
75c66ec88fSEmmanuel Vadot            maxItems: 1
76c66ec88fSEmmanuel Vadot
77c66ec88fSEmmanuel Vadot          clocks:
78c66ec88fSEmmanuel Vadot            description: |
79c66ec88fSEmmanuel Vadot              A number of phandles to clocks that need to be enabled during domain
80c66ec88fSEmmanuel Vadot              power-up sequencing to ensure reset propagation into devices located
81c66ec88fSEmmanuel Vadot              inside this power domain.
82c66ec88fSEmmanuel Vadot            minItems: 1
83c66ec88fSEmmanuel Vadot            maxItems: 7
84c66ec88fSEmmanuel Vadot
85c66ec88fSEmmanuel Vadot          power-supply: true
86c66ec88fSEmmanuel Vadot
87c66ec88fSEmmanuel Vadot        required:
88c66ec88fSEmmanuel Vadot          - '#power-domain-cells'
89c66ec88fSEmmanuel Vadot          - reg
90c66ec88fSEmmanuel Vadot
91c66ec88fSEmmanuel Vadot    required:
92*7ef62cebSEmmanuel Vadot      - '#address-cells'
93*7ef62cebSEmmanuel Vadot      - '#size-cells'
94*7ef62cebSEmmanuel Vadot
95*7ef62cebSEmmanuel Vadotrequired:
96c66ec88fSEmmanuel Vadot  - compatible
97c66ec88fSEmmanuel Vadot  - reg
98c66ec88fSEmmanuel Vadot  - interrupts
99c66ec88fSEmmanuel Vadot  - clocks
100c66ec88fSEmmanuel Vadot  - clock-names
101c66ec88fSEmmanuel Vadot  - pgc
102c66ec88fSEmmanuel Vadot
103c66ec88fSEmmanuel VadotadditionalProperties: false
104c66ec88fSEmmanuel Vadot
105c66ec88fSEmmanuel Vadotexamples:
106c66ec88fSEmmanuel Vadot  - |
107c66ec88fSEmmanuel Vadot    #include <dt-bindings/clock/imx6qdl-clock.h>
108c66ec88fSEmmanuel Vadot    #include <dt-bindings/interrupt-controller/arm-gic.h>
109c66ec88fSEmmanuel Vadot
110c66ec88fSEmmanuel Vadot    gpc@20dc000 {
111c66ec88fSEmmanuel Vadot        compatible = "fsl,imx6q-gpc";
112c66ec88fSEmmanuel Vadot        reg = <0x020dc000 0x4000>;
113c66ec88fSEmmanuel Vadot        interrupts = <0 89 IRQ_TYPE_LEVEL_HIGH>;
114c66ec88fSEmmanuel Vadot        clocks = <&clks IMX6QDL_CLK_IPG>;
115c66ec88fSEmmanuel Vadot        clock-names = "ipg";
116c66ec88fSEmmanuel Vadot
117c66ec88fSEmmanuel Vadot        pgc {
118c66ec88fSEmmanuel Vadot            #address-cells = <1>;
119c66ec88fSEmmanuel Vadot            #size-cells = <0>;
120c66ec88fSEmmanuel Vadot
121c66ec88fSEmmanuel Vadot            power-domain@0 {
122c66ec88fSEmmanuel Vadot                reg = <0>;
123c66ec88fSEmmanuel Vadot                #power-domain-cells = <0>;
124c66ec88fSEmmanuel Vadot            };
125c66ec88fSEmmanuel Vadot
126c66ec88fSEmmanuel Vadot            pd_pu: power-domain@1 {
127c66ec88fSEmmanuel Vadot                reg = <1>;
128c66ec88fSEmmanuel Vadot                #power-domain-cells = <0>;
129c66ec88fSEmmanuel Vadot                power-supply = <&reg_pu>;
130c66ec88fSEmmanuel Vadot                clocks = <&clks IMX6QDL_CLK_GPU3D_CORE>,
131c66ec88fSEmmanuel Vadot                         <&clks IMX6QDL_CLK_GPU3D_SHADER>,
132c66ec88fSEmmanuel Vadot                         <&clks IMX6QDL_CLK_GPU2D_CORE>,
133c66ec88fSEmmanuel Vadot                         <&clks IMX6QDL_CLK_GPU2D_AXI>,
134c66ec88fSEmmanuel Vadot                         <&clks IMX6QDL_CLK_OPENVG_AXI>,
135c66ec88fSEmmanuel Vadot                         <&clks IMX6QDL_CLK_VPU_AXI>;
136c66ec88fSEmmanuel Vadot            };
137c66ec88fSEmmanuel Vadot        };
138c66ec88fSEmmanuel Vadot    };
139