1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/pci/pci-ep-bus.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: Common Properties for PCI MFD EP with Peripherals Addressable from BARs
8
9maintainers:
10  - A. della Porta  <andrea.porta@suse.com>
11
12description:
13  Define a generic node representing a PCI endpoint which contains several sub-
14  peripherals. The peripherals can be accessed through one or more BARs.
15  This common schema is intended to be referenced from device tree bindings and
16  does not represent a device tree binding by itself.
17
18properties:
19  '#address-cells':
20    const: 3
21
22  '#size-cells':
23    const: 2
24
25  ranges:
26    minItems: 1
27    maxItems: 6
28    items:
29      maxItems: 8
30      additionalItems: true
31      items:
32        - maximum: 5  # The BAR number
33        - const: 0
34        - const: 0
35
36patternProperties:
37  '^pci-ep-bus@[0-5]$':
38    type: object
39    description:
40      One node for each BAR used by peripherals contained in the PCI endpoint.
41      Each node represents a bus on which peripherals are connected.
42      This allows for some segmentation, e.g., one peripheral is accessible
43      through BAR0 and another through BAR1, and you don't want the two
44      peripherals to be able to act on the other BAR. Alternatively, when
45      different peripherals need to share BARs, you can define only one node
46      and use a 'ranges' property to map all the used BARs.
47
48    additionalProperties: true
49
50    properties:
51      compatible:
52        const: simple-bus
53
54    required:
55      - compatible
56
57additionalProperties: true
58...
59