xref: /linux/Documentation/devicetree/bindings/remoteproc/qcom,msm8916-mss-pil.yaml (revision daa2be74b1b2302004945b2a5e32424e177cc7da)
1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/remoteproc/qcom,msm8916-mss-pil.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: Qualcomm MSM8916 MSS Peripheral Image Loader (and similar)
8
9maintainers:
10  - Stephan Gerhold <stephan@gerhold.net>
11
12description:
13  This document describes the hardware for a component that loads and boots
14  firmware on the Qualcomm MSM8916 Modem Hexagon Core (and similar).
15
16properties:
17  compatible:
18    oneOf:
19      - enum:
20          - qcom,msm8909-mss-pil
21          - qcom,msm8916-mss-pil
22          - qcom,msm8953-mss-pil
23          - qcom,msm8974-mss-pil
24
25      - const: qcom,q6v5-pil
26        description: Deprecated, prefer using qcom,msm8916-mss-pil
27        deprecated: true
28
29  reg:
30    items:
31      - description: MSS QDSP6 registers
32      - description: RMB registers
33
34  reg-names:
35    items:
36      - const: qdsp6
37      - const: rmb
38
39  interrupts:
40    items:
41      - description: Watchdog interrupt
42      - description: Fatal interrupt
43      - description: Ready interrupt
44      - description: Handover interrupt
45      - description: Stop acknowledge interrupt
46
47  interrupt-names:
48    items:
49      - const: wdog
50      - const: fatal
51      - const: ready
52      - const: handover
53      - const: stop-ack
54
55  clocks:
56    items:
57      - description: Configuration interface (AXI) clock
58      - description: Configuration bus (AHB) clock
59      - description: Boot ROM (AHB) clock
60      - description: XO proxy clock (control handed over after startup)
61
62  clock-names:
63    items:
64      - const: iface
65      - const: bus
66      - const: mem
67      - const: xo
68
69  power-domains:
70    items:
71      - description: CX proxy power domain (control handed over after startup)
72      - description: MX proxy power domain (control handed over after startup)
73      - description: MSS proxy power domain (control handed over after startup)
74                     (only valid for qcom,msm8953-mss-pil)
75    minItems: 2
76
77  power-domain-names:
78    items:
79      - const: cx
80      - const: mx
81      - const: mss # only valid for qcom,msm8953-mss-pil
82    minItems: 2
83
84  pll-supply:
85    description: PLL proxy supply (control handed over after startup)
86
87  mss-supply:
88    description: MSS power domain supply (only valid for qcom,msm8974-mss-pil)
89
90  resets:
91    items:
92      - description: MSS restart control
93
94  reset-names:
95    items:
96      - const: mss_restart
97
98  qcom,smem-states:
99    $ref: /schemas/types.yaml#/definitions/phandle-array
100    description: States used by the AP to signal the Hexagon core
101    items:
102      - description: Stop modem
103
104  qcom,smem-state-names:
105    description: Names of the states used by the AP to signal the Hexagon core
106    items:
107      - const: stop
108
109  qcom,halt-regs:
110    $ref: /schemas/types.yaml#/definitions/phandle-array
111    description:
112      Halt registers are used to halt transactions of various sub-components
113      within MSS.
114    items:
115      - items:
116          - description: phandle to TCSR syscon region
117          - description: offset to the Q6 halt register
118          - description: offset to the modem halt register
119          - description: offset to the nc halt register
120
121  memory-region:
122    items:
123      - description: MBA reserved region
124      - description: MPSS reserved region
125
126  firmware-name:
127    $ref: /schemas/types.yaml#/definitions/string-array
128    items:
129      - description: Name of MBA firmware
130      - description: Name of modem firmware
131
132  bam-dmux:
133    $ref: /schemas/net/qcom,bam-dmux.yaml#
134    description:
135      Qualcomm BAM Data Multiplexer (provides network interface to the modem)
136
137  smd-edge:
138    $ref: qcom,smd-edge.yaml#
139    description:
140      Qualcomm SMD subnode which represents communication edge, channels
141      and devices related to the DSP.
142    properties:
143      label:
144        enum:
145          - modem
146          - hexagon
147    unevaluatedProperties: false
148
149  # Deprecated properties
150  cx-supply:
151    description: CX power domain regulator supply (prefer using power-domains)
152    deprecated: true
153
154  mx-supply:
155    description: MX power domain regulator supply (prefer using power-domains)
156    deprecated: true
157
158  mba:
159    type: object
160    additionalProperties: false
161    description:
162      MBA reserved region (prefer using memory-region with two items)
163    properties:
164      memory-region: true
165    required:
166      - memory-region
167    deprecated: true
168
169  mpss:
170    type: object
171    additionalProperties: false
172    description:
173      MPSS reserved region (prefer using memory-region with two items)
174    properties:
175      memory-region: true
176    required:
177      - memory-region
178    deprecated: true
179
180required:
181  - compatible
182  - reg
183  - reg-names
184  - interrupts
185  - interrupt-names
186  - clocks
187  - clock-names
188  - pll-supply
189  - resets
190  - reset-names
191  - qcom,halt-regs
192  - qcom,smem-states
193  - qcom,smem-state-names
194  - smd-edge
195
196allOf:
197  - if:
198      properties:
199        compatible:
200          const: qcom,msm8953-mss-pil
201    then:
202      properties:
203        power-domains:
204          minItems: 3
205        power-domain-names:
206          minItems: 3
207      required:
208        - power-domains
209        - power-domain-names
210    else:
211      properties:
212        power-domains:
213          maxItems: 2
214        power-domain-names:
215          maxItems: 2
216
217  - if:
218      properties:
219        compatible:
220          const: qcom,msm8974-mss-pil
221    then:
222      required:
223        - mss-supply
224    else:
225      properties:
226        mss-supply: false
227
228  # Fallbacks for deprecated properties
229  - oneOf:
230      - required:
231          - memory-region
232      - required:
233          - mba
234          - mpss
235  - oneOf:
236      - required:
237          - power-domains
238          - power-domain-names
239      - required:
240          - cx-supply
241          - mx-supply
242
243additionalProperties: false
244
245examples:
246  - |
247    #include <dt-bindings/clock/qcom,gcc-msm8916.h>
248    #include <dt-bindings/interrupt-controller/arm-gic.h>
249    #include <dt-bindings/power/qcom-rpmpd.h>
250
251    remoteproc_mpss: remoteproc@4080000 {
252        compatible = "qcom,msm8916-mss-pil";
253        reg = <0x04080000 0x100>, <0x04020000 0x40>;
254        reg-names = "qdsp6", "rmb";
255
256        interrupts-extended = <&intc GIC_SPI 24 IRQ_TYPE_EDGE_RISING>,
257                              <&hexagon_smp2p_in 0 IRQ_TYPE_EDGE_RISING>,
258                              <&hexagon_smp2p_in 1 IRQ_TYPE_EDGE_RISING>,
259                              <&hexagon_smp2p_in 2 IRQ_TYPE_EDGE_RISING>,
260                              <&hexagon_smp2p_in 3 IRQ_TYPE_EDGE_RISING>;
261        interrupt-names = "wdog", "fatal", "ready", "handover", "stop-ack";
262
263        qcom,smem-states = <&hexagon_smp2p_out 0>;
264        qcom,smem-state-names = "stop";
265        qcom,halt-regs = <&tcsr 0x18000 0x19000 0x1a000>;
266
267        clocks = <&gcc GCC_MSS_CFG_AHB_CLK>,
268                 <&gcc GCC_MSS_Q6_BIMC_AXI_CLK>,
269                 <&gcc GCC_BOOT_ROM_AHB_CLK>,
270                 <&xo_board>;
271        clock-names = "iface", "bus", "mem", "xo";
272
273        power-domains = <&rpmpd MSM8916_VDDCX>, <&rpmpd MSM8916_VDDMX>;
274        power-domain-names = "cx", "mx";
275        pll-supply = <&pm8916_l7>;
276
277        resets = <&scm 0>;
278        reset-names = "mss_restart";
279
280        memory-region = <&mba_mem>, <&mpss_mem>;
281
282        smd-edge {
283            interrupts = <GIC_SPI 25 IRQ_TYPE_EDGE_RISING>;
284
285            qcom,smd-edge = <0>;
286            qcom,ipc = <&apcs 8 12>;
287            qcom,remote-pid = <1>;
288
289            label = "hexagon";
290        };
291    };
292