1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/pci/loongson.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: Loongson PCI Host Controller
8
9maintainers:
10  - Jiaxun Yang <jiaxun.yang@flygoat.com>
11
12description: |+
13  PCI host controller found on Loongson PCHs and SoCs.
14
15allOf:
16  - $ref: /schemas/pci/pci-bus.yaml#
17
18properties:
19  compatible:
20    oneOf:
21      - const: loongson,ls2k-pci
22      - const: loongson,ls7a-pci
23      - const: loongson,rs780e-pci
24
25  reg:
26    minItems: 1
27    items:
28      - description: CFG0 standard config space register
29      - description: CFG1 extended config space register
30
31  ranges:
32    minItems: 1
33    maxItems: 3
34
35
36required:
37  - compatible
38  - reg
39  - ranges
40
41unevaluatedProperties: false
42
43examples:
44  - |
45
46    bus {
47        #address-cells = <2>;
48        #size-cells = <2>;
49        pcie@1a000000 {
50            compatible = "loongson,rs780e-pci";
51            device_type = "pci";
52            #address-cells = <3>;
53            #size-cells = <2>;
54
55            // CPU_PHYSICAL(2)  SIZE(2)
56            reg = <0x0 0x1a000000  0x0 0x2000000>;
57
58            // BUS_ADDRESS(3)  CPU_PHYSICAL(2)  SIZE(2)
59            ranges = <0x01000000 0x0 0x00004000  0x0 0x00004000  0x0 0x00004000>,
60                     <0x02000000 0x0 0x40000000  0x0 0x40000000  0x0 0x40000000>;
61        };
62    };
63...
64