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    maxItems: 2
28    items:
29      - description: CFG0 standard config space register
30      - description: CFG1 extended config space register
31
32  ranges:
33    minItems: 1
34    maxItems: 3
35
36
37required:
38  - compatible
39  - reg
40  - ranges
41
42unevaluatedProperties: false
43
44examples:
45  - |
46
47    bus {
48        #address-cells = <2>;
49        #size-cells = <2>;
50        pcie@1a000000 {
51            compatible = "loongson,rs780e-pci";
52            device_type = "pci";
53            #address-cells = <3>;
54            #size-cells = <2>;
55
56            // CPU_PHYSICAL(2)  SIZE(2)
57            reg = <0x0 0x1a000000  0x0 0x2000000>;
58
59            // BUS_ADDRESS(3)  CPU_PHYSICAL(2)  SIZE(2)
60            ranges = <0x01000000 0x0 0x00004000  0x0 0x00004000  0x0 0x00004000>,
61                     <0x02000000 0x0 0x40000000  0x0 0x40000000  0x0 0x40000000>;
62        };
63    };
64...
65