blob: b3837368a2606ab40c11d8665627de7645181ec5 [file] [log] [blame]
Tom Rini53633a82024-02-29 12:33:36 -05001# SPDX-License-Identifier: GPL-2.0-only
2# Copyright 2019-2020, The Linux Foundation, All Rights Reserved
3%YAML 1.2
4---
5
6$id: http://devicetree.org/schemas/display/msm/gmu.yaml#
7$schema: http://devicetree.org/meta-schemas/core.yaml#
8
9title: GMU attached to certain Adreno GPUs
10
11maintainers:
12 - Rob Clark <robdclark@gmail.com>
13
14description: |
15 These bindings describe the Graphics Management Unit (GMU) that is attached
16 to members of the Adreno A6xx GPU family. The GMU provides on-device power
17 management and support to improve power efficiency and reduce the load on
18 the CPU.
19
20properties:
21 compatible:
22 oneOf:
23 - items:
24 - pattern: '^qcom,adreno-gmu-[67][0-9][0-9]\.[0-9]$'
25 - const: qcom,adreno-gmu
26 - const: qcom,adreno-gmu-wrapper
27
28 reg:
29 minItems: 1
30 maxItems: 4
31
32 reg-names:
33 minItems: 1
34 maxItems: 4
35
36 clocks:
37 minItems: 4
38 maxItems: 7
39
40 clock-names:
41 minItems: 4
42 maxItems: 7
43
44 interrupts:
45 items:
46 - description: GMU HFI interrupt
47 - description: GMU interrupt
48
49 interrupt-names:
50 items:
51 - const: hfi
52 - const: gmu
53
54 power-domains:
55 items:
56 - description: CX power domain
57 - description: GX power domain
58
59 power-domain-names:
60 items:
61 - const: cx
62 - const: gx
63
64 iommus:
65 maxItems: 1
66
67 qcom,qmp:
68 $ref: /schemas/types.yaml#/definitions/phandle
69 description: Reference to the AOSS side-channel message RAM
70
71 operating-points-v2: true
72
73 opp-table:
74 type: object
75
76required:
77 - compatible
78 - reg
79 - reg-names
80 - power-domains
81 - power-domain-names
82
83additionalProperties: false
84
85allOf:
86 - if:
87 properties:
88 compatible:
89 contains:
90 enum:
91 - qcom,adreno-gmu-618.0
92 - qcom,adreno-gmu-630.2
93 then:
94 properties:
95 reg:
96 items:
97 - description: Core GMU registers
98 - description: GMU PDC registers
99 - description: GMU PDC sequence registers
100 reg-names:
101 items:
102 - const: gmu
103 - const: gmu_pdc
104 - const: gmu_pdc_seq
105 clocks:
106 items:
107 - description: GMU clock
108 - description: GPU CX clock
109 - description: GPU AXI clock
110 - description: GPU MEMNOC clock
111 clock-names:
112 items:
113 - const: gmu
114 - const: cxo
115 - const: axi
116 - const: memnoc
117
118 - if:
119 properties:
120 compatible:
121 contains:
122 enum:
123 - qcom,adreno-gmu-635.0
124 - qcom,adreno-gmu-660.1
125 then:
126 properties:
127 reg:
128 items:
129 - description: Core GMU registers
130 - description: Resource controller registers
131 - description: GMU PDC registers
132 reg-names:
133 items:
134 - const: gmu
135 - const: rscc
136 - const: gmu_pdc
137 clocks:
138 items:
139 - description: GMU clock
140 - description: GPU CX clock
141 - description: GPU AXI clock
142 - description: GPU MEMNOC clock
143 - description: GPU AHB clock
144 - description: GPU HUB CX clock
145 - description: GPU SMMU vote clock
146 clock-names:
147 items:
148 - const: gmu
149 - const: cxo
150 - const: axi
151 - const: memnoc
152 - const: ahb
153 - const: hub
154 - const: smmu_vote
155
156 - if:
157 properties:
158 compatible:
159 contains:
160 enum:
161 - qcom,adreno-gmu-640.1
162 then:
163 properties:
164 reg:
165 items:
166 - description: Core GMU registers
167 - description: GMU PDC registers
168 - description: GMU PDC sequence registers
169 reg-names:
170 items:
171 - const: gmu
172 - const: gmu_pdc
173 - const: gmu_pdc_seq
174
175 - if:
176 properties:
177 compatible:
178 contains:
179 enum:
180 - qcom,adreno-gmu-650.2
181 then:
182 properties:
183 reg:
184 items:
185 - description: Core GMU registers
186 - description: Resource controller registers
187 - description: GMU PDC registers
188 - description: GMU PDC sequence registers
189 reg-names:
190 items:
191 - const: gmu
192 - const: rscc
193 - const: gmu_pdc
194 - const: gmu_pdc_seq
195
196 - if:
197 properties:
198 compatible:
199 contains:
200 enum:
201 - qcom,adreno-gmu-640.1
202 - qcom,adreno-gmu-650.2
203 then:
204 properties:
205 clocks:
206 items:
207 - description: GPU AHB clock
208 - description: GMU clock
209 - description: GPU CX clock
210 - description: GPU AXI clock
211 - description: GPU MEMNOC clock
212 clock-names:
213 items:
214 - const: ahb
215 - const: gmu
216 - const: cxo
217 - const: axi
218 - const: memnoc
219
220 - if:
221 properties:
222 compatible:
223 contains:
224 enum:
225 - qcom,adreno-gmu-730.1
226 - qcom,adreno-gmu-740.1
Tom Rini6bb92fc2024-05-20 09:54:58 -0600227 - qcom,adreno-gmu-750.1
Tom Rini53633a82024-02-29 12:33:36 -0500228 then:
229 properties:
230 reg:
231 items:
232 - description: Core GMU registers
233 - description: Resource controller registers
234 - description: GMU PDC registers
235 reg-names:
236 items:
237 - const: gmu
238 - const: rscc
239 - const: gmu_pdc
240 clocks:
241 items:
242 - description: GPU AHB clock
243 - description: GMU clock
244 - description: GPU CX clock
245 - description: GPU AXI clock
246 - description: GPU MEMNOC clock
247 - description: GMU HUB clock
248 - description: GPUSS DEMET clock
249 clock-names:
250 items:
251 - const: ahb
252 - const: gmu
253 - const: cxo
254 - const: axi
255 - const: memnoc
256 - const: hub
257 - const: demet
258
259 required:
260 - qcom,qmp
261
262 - if:
263 properties:
264 compatible:
265 contains:
266 const: qcom,adreno-gmu-wrapper
267 then:
268 properties:
269 reg:
270 items:
271 - description: GMU wrapper register space
272 reg-names:
273 items:
274 - const: gmu
275 else:
276 required:
277 - clocks
278 - clock-names
279 - interrupts
280 - interrupt-names
281 - iommus
282 - operating-points-v2
283
284examples:
285 - |
286 #include <dt-bindings/clock/qcom,gpucc-sdm845.h>
287 #include <dt-bindings/clock/qcom,gcc-sdm845.h>
288 #include <dt-bindings/interrupt-controller/irq.h>
289 #include <dt-bindings/interrupt-controller/arm-gic.h>
290
291 gmu: gmu@506a000 {
292 compatible = "qcom,adreno-gmu-630.2", "qcom,adreno-gmu";
293
294 reg = <0x506a000 0x30000>,
295 <0xb280000 0x10000>,
296 <0xb480000 0x10000>;
297 reg-names = "gmu", "gmu_pdc", "gmu_pdc_seq";
298
299 clocks = <&gpucc GPU_CC_CX_GMU_CLK>,
300 <&gpucc GPU_CC_CXO_CLK>,
301 <&gcc GCC_DDRSS_GPU_AXI_CLK>,
302 <&gcc GCC_GPU_MEMNOC_GFX_CLK>;
303 clock-names = "gmu", "cxo", "axi", "memnoc";
304
305 interrupts = <GIC_SPI 304 IRQ_TYPE_LEVEL_HIGH>,
306 <GIC_SPI 305 IRQ_TYPE_LEVEL_HIGH>;
307 interrupt-names = "hfi", "gmu";
308
309 power-domains = <&gpucc GPU_CX_GDSC>,
310 <&gpucc GPU_GX_GDSC>;
311 power-domain-names = "cx", "gx";
312
313 iommus = <&adreno_smmu 5>;
314 operating-points-v2 = <&gmu_opp_table>;
315 };
316
317 gmu_wrapper: gmu@596a000 {
318 compatible = "qcom,adreno-gmu-wrapper";
319 reg = <0x0596a000 0x30000>;
320 reg-names = "gmu";
321 power-domains = <&gpucc GPU_CX_GDSC>,
322 <&gpucc GPU_GX_GDSC>;
323 power-domain-names = "cx", "gx";
324 };