Debian Codegraph @

dtschema/schemas/pci/pci-bus-common.yaml

raw
1 # SPDX-License-Identifier: (GPL2.0-only OR BSD-2-Clause)
2 # Copyright 2018 Linaro Ltd.
3 # Copyright 2024 Arm Ltd.
4 %YAML 1.2
5 ---
6 $id: http://devicetree.org/schemas/pci/pci-bus-common.yaml#
7 $schema: http://devicetree.org/meta-schemas/base.yaml#
8
9 title: PCI Bus Common Properties
10
11 description: |
12 Common properties for PCI bus structure.
13
14 PCI bus bridges have standardized Device Tree bindings:
15
16 PCI Bus Binding to: IEEE Std 1275-1994
17 http://www.devicetree.org/open-firmware/bindings/pci/pci2_1.pdf
18
19 And for the interrupt mapping part:
20
21 Open Firmware Recommended Practice: Interrupt Mapping
22 http://www.devicetree.org/open-firmware/practice/imap/imap0_9d.pdf
23
24 maintainers:
25 - Rob Herring <[email protected]>
26
27 properties:
28 $nodename:
29 pattern: "^pcie?@"
30
31 ranges:
32 oneOf:
33 - type: boolean
34 - minItems: 1
35 maxItems: 32 # Should be enough
36 items:
37 minItems: 5
38 maxItems: 8
39 additionalItems: true
40 items:
41 - enum:
42 - 0x01000000
43 - 0x02000000
44 - 0x03000000
45 - 0x42000000
46 - 0x43000000
47 - 0x81000000
48 - 0x82000000
49 - 0x83000000
50 - 0xc2000000
51 - 0xc3000000
52
53 dma-ranges:
54 oneOf:
55 - type: boolean
56 - minItems: 1
57 maxItems: 32 # Should be enough
58 items:
59 minItems: 5
60 maxItems: 8
61 additionalItems: true
62 items:
63 - enum:
64 - 0x02000000
65 - 0x03000000
66 - 0x42000000
67 - 0x43000000
68
69 "#address-cells":
70 const: 3
71
72 "#size-cells":
73 const: 2
74
75 device_type:
76 const: pci
77
78 bus-range:
79 $ref: /schemas/types.yaml#/definitions/uint32-array
80 minItems: 2
81 maxItems: 2
82 items:
83 maximum: 255
84
85 external-facing:
86 description:
87 When present, the port is externally facing. All bridges and endpoints
88 downstream of this port are external to the machine. The OS can, for
89 example, use this information to identify devices that cannot be
90 trusted with relaxed DMA protection, as users could easily attach
91 malicious devices to this port.
92 type: boolean
93
94 "#interrupt-cells":
95 const: 1
96
97 interrupt-map: true
98 # minItems: 1
99 # maxItems: 88 # 22 IDSEL x 4 IRQs
100 # items:
101 # minItems: 6 # 3 addr cells, 1 PCI IRQ cell, 1 phandle, 1+ parent addr and IRQ cells
102 # maxItems: 16
103
104 interrupt-map-mask:
105 items:
106 - description: PCI high address cell
107 minimum: 0
108 maximum: 0xff00
109 - description: PCI mid address cell
110 const: 0
111 - description: PCI low address cell
112 const: 0
113 - description: PCI IRQ cell
114 minimum: 0
115 maximum: 7
116
117 max-link-speed:
118 description:
119 If present this property specifies PCI generation number for link
120 capability. Host drivers could add this as a strategy to avoid
121 unnecessary operation for unsupported link speed, for instance, trying to
122 do training for unsupported link speed, etc.
123 $ref: /schemas/types.yaml#/definitions/uint32
124 enum: [ 1, 2, 3, 4 ]
125
126 num-lanes:
127 description: The number of PCIe lanes
128 $ref: /schemas/types.yaml#/definitions/uint32
129 enum: [ 1, 2, 4, 8, 16, 32 ]
130
131 n-fts:
132 description:
133 The number of Fast Training Sequences (N_FTS) required by the
134 Receiver (this component) when transitioning the Link from L0s
135 to L0; advertised during initial Link training. Each entry in
136 the array specifies a PCIe data rate
137 $ref: /schemas/types.yaml#/definitions/uint8-array
138 minItems: 1
139 maxItems: 5
140
141 reset-gpios:
142 description: GPIO controlled connection to PERST# signal
143 maxItems: 1
144
145 wake-gpios:
146 description: GPIO controlled connection to WAKE# signal
147 maxItems: 1
148
149 slot-power-limit-milliwatt:
150 description:
151 If present, specifies slot power limit in milliwatts.
152 This property is invalid in host bridge nodes.
153 maxItems: 1
154
155 supports-clkreq:
156 description:
157 If present this property specifies that CLKREQ signal routing exists from
158 root port to downstream device and host bridge drivers can do programming
159 which depends on CLKREQ signal existence. For example, programming root port
160 not to advertise ASPM L1 Sub-States support if there is no CLKREQ signal.
161 type: boolean
162
163 aspm-no-l0s:
164 description: Disables ASPM L0s capability
165 type: boolean
166
167 aspm-l0s-entry-delay-ns:
168 description: ASPM L0s entry delay
169
170 aspm-l1-entry-delay-ns:
171 description: ASPM L1 entry delay
172
173 vpcie12v-supply:
174 description: 12v regulator phandle for the slot
175
176 vpcie3v3-supply:
177 description: 3.3v regulator phandle for the slot
178
179 vpcie3v3aux-supply:
180 description: 3.3v AUX regulator phandle for the slot
181
182 eq-presets-8gts:
183 description:
184 Contains the equalization preset values for PCIe data rates 8.0 GT/s.
185 Each preset value is used to adjust the transmitter settings to improve
186 signal quality and meet the electrical requirements. These preset values
187 go in Lane Equalization Control registers (PCIe r6.0, sec 7.7.3.4).
188 $ref: /schemas/types.yaml#/definitions/uint16-array
189 minItems: 1
190 maxItems: 16
191
192 eq-presets-16gts:
193 description:
194 Contains the equalization preset values for PCIe data rates 16.0 GT/s.
195 Each preset value is used to adjust the transmitter settings to improve
196 signal quality and meet the electrical requirements. These preset values
197 go in Lane Equalization Control registers (PCIe r6.0, sec 7.7.5.9).
198 $ref: /schemas/types.yaml#/definitions/uint8-array
199 minItems: 1
200 maxItems: 16
201
202 eq-presets-32gts:
203 description:
204 Contains the equalization preset values for PCIe data rates 32.0 GT/s.
205 Each preset value is used to adjust the transmitter settings to improve
206 signal quality and meet the electrical requirements. These preset values
207 go in Lane Equalization Control registers (PCIe r6.0, sec 7.7.6.9).
208 $ref: /schemas/types.yaml#/definitions/uint8-array
209 minItems: 1
210 maxItems: 16
211
212 eq-presets-64gts:
213 description:
214 Contains the equalization preset values for PCIe data rates 64.0 GT/s.
215 Each preset value is used to adjust the transmitter settings to improve
216 signal quality and meet the electrical requirements. These preset values
217 go in Lane Equalization Control registers (PCIe r6.0, sec 7.7.7.5).
218 $ref: /schemas/types.yaml#/definitions/uint8-array
219 minItems: 1
220 maxItems: 16
221
222 patternProperties:
223 "@1?[0-9a-f](,[0-7])?$":
224 type: object
225 $ref: pci-device.yaml#
226 additionalProperties: true
227
228 required:
229 - device_type
230 - ranges
231 - "#address-cells"
232 - "#size-cells"
233
234 additionalProperties: true