xref: /linux/Documentation/devicetree/bindings/sram/qcom,imem.yaml (revision 3a2c4d55e32ad65efebdb6de44eef3bfa08bb49d)
1# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/sram/qcom,imem.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: Qualcomm IMEM memory region
8
9maintainers:
10  - Bjorn Andersson <bjorn.andersson@linaro.org>
11
12description:
13  Qualcomm IMEM is dedicated memory region for various debug features and DMA
14  transactions.
15
16properties:
17  compatible:
18    items:
19      - enum:
20          - qcom,apq8064-imem
21          - qcom,ipq5424-imem
22          - qcom,msm8226-imem
23          - qcom,msm8974-imem
24          - qcom,msm8976-imem
25          - qcom,qcs404-imem
26          - qcom,qcs615-imem
27          - qcom,qcs8300-imem
28          - qcom,qdu1000-imem
29          - qcom,sa8775p-imem
30          - qcom,sar2130p-imem
31          - qcom,sc7180-imem
32          - qcom,sc7280-imem
33          - qcom,sc8280xp-imem
34          - qcom,sdm630-imem
35          - qcom,sdm845-imem
36          - qcom,sdx55-imem
37          - qcom,sdx65-imem
38          - qcom,sdx75-imem
39          - qcom,sm6115-imem
40          - qcom,sm6125-imem
41          - qcom,sm6350-imem
42          - qcom,sm6375-imem
43          - qcom,sm7150-imem
44          - qcom,sm8150-imem
45          - qcom,sm8250-imem
46          - qcom,sm8350-imem
47          - qcom,sm8450-imem
48          - qcom,sm8550-imem
49          - qcom,sm8650-imem
50          - qcom,sm8750-imem
51          - qcom,x1e80100-imem
52      - const: syscon
53      - const: simple-mfd
54
55  reg:
56    maxItems: 1
57
58  ranges: true
59
60  '#address-cells':
61    const: 1
62
63  '#size-cells':
64    const: 1
65
66  reboot-mode:
67    $ref: /schemas/power/reset/syscon-reboot-mode.yaml#
68
69patternProperties:
70  "^minidump-sram@[0-9a-f]+$":
71    type: object
72    description:
73      A word in always-on SRAM shared between the kernel and boot firmware.
74      Before DDR is initialised on the warm reset following a crash, firmware
75      reads this word to decide where to deliver the minidump (USB or storage).
76
77    properties:
78      reg:
79        maxItems: 1
80
81    required:
82      - reg
83
84    additionalProperties: false
85
86  "^modem-tables@[0-9a-f]+$":
87    type: object
88    description:
89      Region containing packet processing configuration for the IP Accelerator.
90
91    properties:
92      reg:
93        maxItems: 1
94
95    required:
96      - reg
97
98    additionalProperties: false
99
100  "^pil-reloc@[0-9a-f]+$":
101    $ref: /schemas/remoteproc/qcom,pil-info.yaml#
102    description: Peripheral image loader relocation region
103
104required:
105  - compatible
106  - reg
107
108allOf:
109  - if:
110      properties:
111        compatible:
112          contains:
113            enum:
114              - qcom,apq8064-imem
115              - qcom,msm8226-imem
116              - qcom,msm8974-imem
117    then:
118      properties:
119        reboot-mode:
120          patternProperties:
121            # Negative look-ahead to disallow unsupported modes. The '$' has to be
122            # part of lookahead group to work, instead of trailing outside of ().
123            "^mode-(?!(bootloader$|normal$|recovery$))": false
124    else:
125      properties:
126        reboot-mode: false
127
128additionalProperties: false
129
130examples:
131  - |
132    soc {
133        #address-cells = <2>;
134        #size-cells = <2>;
135
136        sram@146bf000 {
137            compatible = "qcom,sdm845-imem", "syscon", "simple-mfd";
138            reg = <0 0x146bf000 0 0x1000>;
139            ranges = <0 0 0x146bf000 0x1000>;
140
141            #address-cells = <1>;
142            #size-cells = <1>;
143
144            pil-reloc@94c {
145                compatible = "qcom,pil-reloc-info";
146                reg = <0x94c 0xc8>;
147            };
148        };
149    };
150