xref: /freebsd/sys/contrib/device-tree/Bindings/pci/loongson.yaml (revision cfd6422a5217410fbd66f7a7a8a64d9d85e61229)
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
42examples:
43  - |
44
45    bus {
46        #address-cells = <2>;
47        #size-cells = <2>;
48        pcie@1a000000 {
49            compatible = "loongson,rs780e-pci";
50            device_type = "pci";
51            #address-cells = <3>;
52            #size-cells = <2>;
53
54            // CPU_PHYSICAL(2)  SIZE(2)
55            reg = <0x0 0x1a000000  0x0 0x2000000>;
56
57            // BUS_ADDRESS(3)  CPU_PHYSICAL(2)  SIZE(2)
58            ranges = <0x01000000 0x0 0x00004000  0x0 0x00004000  0x0 0x00004000>,
59                     <0x02000000 0x0 0x40000000  0x0 0x40000000  0x0 0x40000000>;
60        };
61    };
62...
63