xref: /freebsd/sys/contrib/device-tree/Bindings/pci/qcom,pcie-sc8280xp.yaml (revision b2d2a78ad80ec68d4a17f5aef97d21686cb1e29b)
1*01950c46SEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2*01950c46SEmmanuel Vadot%YAML 1.2
3*01950c46SEmmanuel Vadot---
4*01950c46SEmmanuel Vadot$id: http://devicetree.org/schemas/pci/qcom,pcie-sc8280xp.yaml#
5*01950c46SEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6*01950c46SEmmanuel Vadot
7*01950c46SEmmanuel Vadottitle: Qualcomm SC8280XP PCI Express Root Complex
8*01950c46SEmmanuel Vadot
9*01950c46SEmmanuel Vadotmaintainers:
10*01950c46SEmmanuel Vadot  - Bjorn Andersson <andersson@kernel.org>
11*01950c46SEmmanuel Vadot  - Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
12*01950c46SEmmanuel Vadot
13*01950c46SEmmanuel Vadotdescription:
14*01950c46SEmmanuel Vadot  Qualcomm SC8280XP SoC PCIe root complex controller is based on the Synopsys
15*01950c46SEmmanuel Vadot  DesignWare PCIe IP.
16*01950c46SEmmanuel Vadot
17*01950c46SEmmanuel Vadotproperties:
18*01950c46SEmmanuel Vadot  compatible:
19*01950c46SEmmanuel Vadot    enum:
20*01950c46SEmmanuel Vadot      - qcom,pcie-sa8540p
21*01950c46SEmmanuel Vadot      - qcom,pcie-sc8280xp
22*01950c46SEmmanuel Vadot
23*01950c46SEmmanuel Vadot  reg:
24*01950c46SEmmanuel Vadot    minItems: 5
25*01950c46SEmmanuel Vadot    maxItems: 6
26*01950c46SEmmanuel Vadot
27*01950c46SEmmanuel Vadot  reg-names:
28*01950c46SEmmanuel Vadot    minItems: 5
29*01950c46SEmmanuel Vadot    items:
30*01950c46SEmmanuel Vadot      - const: parf # Qualcomm specific registers
31*01950c46SEmmanuel Vadot      - const: dbi # DesignWare PCIe registers
32*01950c46SEmmanuel Vadot      - const: elbi # External local bus interface registers
33*01950c46SEmmanuel Vadot      - const: atu # ATU address space
34*01950c46SEmmanuel Vadot      - const: config # PCIe configuration space
35*01950c46SEmmanuel Vadot      - const: mhi # MHI registers
36*01950c46SEmmanuel Vadot
37*01950c46SEmmanuel Vadot  clocks:
38*01950c46SEmmanuel Vadot    minItems: 8
39*01950c46SEmmanuel Vadot    maxItems: 9
40*01950c46SEmmanuel Vadot
41*01950c46SEmmanuel Vadot  clock-names:
42*01950c46SEmmanuel Vadot    minItems: 8
43*01950c46SEmmanuel Vadot    items:
44*01950c46SEmmanuel Vadot      - const: aux # Auxiliary clock
45*01950c46SEmmanuel Vadot      - const: cfg # Configuration clock
46*01950c46SEmmanuel Vadot      - const: bus_master # Master AXI clock
47*01950c46SEmmanuel Vadot      - const: bus_slave # Slave AXI clock
48*01950c46SEmmanuel Vadot      - const: slave_q2a # Slave Q2A clock
49*01950c46SEmmanuel Vadot      - const: ddrss_sf_tbu # PCIe SF TBU clock
50*01950c46SEmmanuel Vadot      - const: noc_aggr_4 # NoC aggregate 4 clock
51*01950c46SEmmanuel Vadot      - const: noc_aggr_south_sf # NoC aggregate South SF clock
52*01950c46SEmmanuel Vadot      - const: cnoc_qx # Configuration NoC QX clock
53*01950c46SEmmanuel Vadot
54*01950c46SEmmanuel Vadot  resets:
55*01950c46SEmmanuel Vadot    maxItems: 1
56*01950c46SEmmanuel Vadot
57*01950c46SEmmanuel Vadot  reset-names:
58*01950c46SEmmanuel Vadot    items:
59*01950c46SEmmanuel Vadot      - const: pci
60*01950c46SEmmanuel Vadot
61*01950c46SEmmanuel Vadotrequired:
62*01950c46SEmmanuel Vadot  - interconnects
63*01950c46SEmmanuel Vadot  - interconnect-names
64*01950c46SEmmanuel Vadot
65*01950c46SEmmanuel VadotallOf:
66*01950c46SEmmanuel Vadot  - $ref: qcom,pcie-common.yaml#
67*01950c46SEmmanuel Vadot  - if:
68*01950c46SEmmanuel Vadot      properties:
69*01950c46SEmmanuel Vadot        compatible:
70*01950c46SEmmanuel Vadot          contains:
71*01950c46SEmmanuel Vadot            enum:
72*01950c46SEmmanuel Vadot              - qcom,pcie-sc8280xp
73*01950c46SEmmanuel Vadot    then:
74*01950c46SEmmanuel Vadot      properties:
75*01950c46SEmmanuel Vadot        interrupts:
76*01950c46SEmmanuel Vadot          minItems: 4
77*01950c46SEmmanuel Vadot          maxItems: 4
78*01950c46SEmmanuel Vadot        interrupt-names:
79*01950c46SEmmanuel Vadot          items:
80*01950c46SEmmanuel Vadot            - const: msi0
81*01950c46SEmmanuel Vadot            - const: msi1
82*01950c46SEmmanuel Vadot            - const: msi2
83*01950c46SEmmanuel Vadot            - const: msi3
84*01950c46SEmmanuel Vadot    else:
85*01950c46SEmmanuel Vadot      properties:
86*01950c46SEmmanuel Vadot        interrupts:
87*01950c46SEmmanuel Vadot          maxItems: 1
88*01950c46SEmmanuel Vadot        interrupt-names:
89*01950c46SEmmanuel Vadot          items:
90*01950c46SEmmanuel Vadot            - const: msi
91*01950c46SEmmanuel Vadot
92*01950c46SEmmanuel VadotunevaluatedProperties: false
93*01950c46SEmmanuel Vadot
94*01950c46SEmmanuel Vadotexamples:
95*01950c46SEmmanuel Vadot  - |
96*01950c46SEmmanuel Vadot    #include <dt-bindings/clock/qcom,gcc-sc8280xp.h>
97*01950c46SEmmanuel Vadot    #include <dt-bindings/gpio/gpio.h>
98*01950c46SEmmanuel Vadot    #include <dt-bindings/interconnect/qcom,sc8280xp.h>
99*01950c46SEmmanuel Vadot    #include <dt-bindings/interrupt-controller/arm-gic.h>
100*01950c46SEmmanuel Vadot
101*01950c46SEmmanuel Vadot    soc {
102*01950c46SEmmanuel Vadot        #address-cells = <2>;
103*01950c46SEmmanuel Vadot        #size-cells = <2>;
104*01950c46SEmmanuel Vadot
105*01950c46SEmmanuel Vadot        pcie@1c20000 {
106*01950c46SEmmanuel Vadot            compatible = "qcom,pcie-sc8280xp";
107*01950c46SEmmanuel Vadot            reg = <0x0 0x01c20000 0x0 0x3000>,
108*01950c46SEmmanuel Vadot                  <0x0 0x3c000000 0x0 0xf1d>,
109*01950c46SEmmanuel Vadot                  <0x0 0x3c000f20 0x0 0xa8>,
110*01950c46SEmmanuel Vadot                  <0x0 0x3c001000 0x0 0x1000>,
111*01950c46SEmmanuel Vadot                  <0x0 0x3c100000 0x0 0x100000>,
112*01950c46SEmmanuel Vadot                  <0x0 0x01c23000 0x0 0x1000>;
113*01950c46SEmmanuel Vadot            reg-names = "parf", "dbi", "elbi", "atu", "config", "mhi";
114*01950c46SEmmanuel Vadot            ranges = <0x01000000 0x0 0x00000000 0x0 0x3c200000 0x0 0x100000>,
115*01950c46SEmmanuel Vadot                     <0x02000000 0x0 0x3c300000 0x0 0x3c300000 0x0 0x1d00000>;
116*01950c46SEmmanuel Vadot
117*01950c46SEmmanuel Vadot            bus-range = <0x00 0xff>;
118*01950c46SEmmanuel Vadot            device_type = "pci";
119*01950c46SEmmanuel Vadot            linux,pci-domain = <2>;
120*01950c46SEmmanuel Vadot            num-lanes = <4>;
121*01950c46SEmmanuel Vadot
122*01950c46SEmmanuel Vadot            #address-cells = <3>;
123*01950c46SEmmanuel Vadot            #size-cells = <2>;
124*01950c46SEmmanuel Vadot
125*01950c46SEmmanuel Vadot            assigned-clocks = <&gcc GCC_PCIE_2A_AUX_CLK>;
126*01950c46SEmmanuel Vadot            assigned-clock-rates = <19200000>;
127*01950c46SEmmanuel Vadot            clocks = <&gcc GCC_PCIE_2A_AUX_CLK>,
128*01950c46SEmmanuel Vadot                     <&gcc GCC_PCIE_2A_CFG_AHB_CLK>,
129*01950c46SEmmanuel Vadot                     <&gcc GCC_PCIE_2A_MSTR_AXI_CLK>,
130*01950c46SEmmanuel Vadot                     <&gcc GCC_PCIE_2A_SLV_AXI_CLK>,
131*01950c46SEmmanuel Vadot                     <&gcc GCC_PCIE_2A_SLV_Q2A_AXI_CLK>,
132*01950c46SEmmanuel Vadot                     <&gcc GCC_DDRSS_PCIE_SF_TBU_CLK>,
133*01950c46SEmmanuel Vadot                     <&gcc GCC_AGGRE_NOC_PCIE_4_AXI_CLK>,
134*01950c46SEmmanuel Vadot                     <&gcc GCC_AGGRE_NOC_PCIE_SOUTH_SF_AXI_CLK>;
135*01950c46SEmmanuel Vadot            clock-names = "aux",
136*01950c46SEmmanuel Vadot                          "cfg",
137*01950c46SEmmanuel Vadot                          "bus_master",
138*01950c46SEmmanuel Vadot                          "bus_slave",
139*01950c46SEmmanuel Vadot                          "slave_q2a",
140*01950c46SEmmanuel Vadot                          "ddrss_sf_tbu",
141*01950c46SEmmanuel Vadot                          "noc_aggr_4",
142*01950c46SEmmanuel Vadot                          "noc_aggr_south_sf";
143*01950c46SEmmanuel Vadot
144*01950c46SEmmanuel Vadot            dma-coherent;
145*01950c46SEmmanuel Vadot
146*01950c46SEmmanuel Vadot            interrupts = <GIC_SPI 86 IRQ_TYPE_LEVEL_HIGH>,
147*01950c46SEmmanuel Vadot                         <GIC_SPI 523 IRQ_TYPE_LEVEL_HIGH>,
148*01950c46SEmmanuel Vadot                         <GIC_SPI 524 IRQ_TYPE_LEVEL_HIGH>,
149*01950c46SEmmanuel Vadot                         <GIC_SPI 525 IRQ_TYPE_LEVEL_HIGH>;
150*01950c46SEmmanuel Vadot            interrupt-names = "msi0", "msi1", "msi2", "msi3";
151*01950c46SEmmanuel Vadot            #interrupt-cells = <1>;
152*01950c46SEmmanuel Vadot            interrupt-map-mask = <0 0 0 0x7>;
153*01950c46SEmmanuel Vadot            interrupt-map = <0 0 0 1 &intc 0 0 GIC_SPI 530 IRQ_TYPE_LEVEL_HIGH>,
154*01950c46SEmmanuel Vadot                            <0 0 0 2 &intc 0 0 GIC_SPI 531 IRQ_TYPE_LEVEL_HIGH>,
155*01950c46SEmmanuel Vadot                            <0 0 0 3 &intc 0 0 GIC_SPI 532 IRQ_TYPE_LEVEL_HIGH>,
156*01950c46SEmmanuel Vadot                            <0 0 0 4 &intc 0 0 GIC_SPI 533 IRQ_TYPE_LEVEL_HIGH>;
157*01950c46SEmmanuel Vadot
158*01950c46SEmmanuel Vadot            interconnects = <&aggre2_noc MASTER_PCIE_2A 0 &mc_virt SLAVE_EBI1 0>,
159*01950c46SEmmanuel Vadot                            <&gem_noc MASTER_APPSS_PROC 0 &config_noc SLAVE_PCIE_2A 0>;
160*01950c46SEmmanuel Vadot            interconnect-names = "pcie-mem", "cpu-pcie";
161*01950c46SEmmanuel Vadot
162*01950c46SEmmanuel Vadot            phys = <&pcie2a_phy>;
163*01950c46SEmmanuel Vadot            phy-names = "pciephy";
164*01950c46SEmmanuel Vadot
165*01950c46SEmmanuel Vadot            pinctrl-0 = <&pcie2a_default>;
166*01950c46SEmmanuel Vadot            pinctrl-names = "default";
167*01950c46SEmmanuel Vadot
168*01950c46SEmmanuel Vadot            power-domains = <&gcc PCIE_2A_GDSC>;
169*01950c46SEmmanuel Vadot
170*01950c46SEmmanuel Vadot            resets = <&gcc GCC_PCIE_2A_BCR>;
171*01950c46SEmmanuel Vadot            reset-names = "pci";
172*01950c46SEmmanuel Vadot
173*01950c46SEmmanuel Vadot            perst-gpios = <&tlmm 143 GPIO_ACTIVE_LOW>;
174*01950c46SEmmanuel Vadot            wake-gpios = <&tlmm 145 GPIO_ACTIVE_LOW>;
175*01950c46SEmmanuel Vadot            vddpe-3v3-supply = <&vreg_nvme>;
176*01950c46SEmmanuel Vadot        };
177*01950c46SEmmanuel Vadot    };
178