Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dt-bindings: PCI: kirin: Add support for Kirin970

Add a new compatible, plus the new bindings needed by
HiKey970 board.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Link: https://lore.kernel.org/r/875a4571e253040d3885ee1f37467b0bade7361b.1628061310.git.mchehab+huawei@kernel.org
Signed-off-by: Rob Herring <robh@kernel.org>

authored by

Mauro Carvalho Chehab and committed by
Rob Herring
cfcf126f 78e29356

+82 -1
+82 -1
Documentation/devicetree/bindings/pci/hisilicon,kirin-pcie.yaml
··· 24 24 contains: 25 25 enum: 26 26 - hisilicon,kirin960-pcie 27 + - hisilicon,kirin970-pcie 27 28 28 29 reg: 29 30 description: | 30 31 Should contain dbi, apb, config registers location and length. 31 - For HiKey960, it should also contain phy. 32 + For hisilicon,kirin960-pcie, it should also contain phy. 32 33 minItems: 3 33 34 maxItems: 4 34 35 35 36 reg-names: 36 37 minItems: 3 37 38 maxItems: 4 39 + 40 + hisilicon,clken-gpios: 41 + description: | 42 + Clock input enablement GPIOs from PCI devices like Ethernet, M.2 and 43 + mini-PCIe slots. 38 44 39 45 required: 40 46 - compatible ··· 53 47 - | 54 48 #include <dt-bindings/interrupt-controller/arm-gic.h> 55 49 #include <dt-bindings/clock/hi3660-clock.h> 50 + #include <dt-bindings/clock/hi3670-clock.h> 56 51 57 52 soc { 58 53 #address-cells = <2>; ··· 89 82 <&crg_ctrl HI3660_ACLK_GATE_PCIE>; 90 83 clock-names = "pcie_phy_ref", "pcie_aux", "pcie_apb_phy", 91 84 "pcie_apb_sys", "pcie_aclk"; 85 + }; 86 + 87 + pcie@f5000000 { 88 + compatible = "hisilicon,kirin970-pcie"; 89 + reg = <0x0 0xf4000000 0x0 0x1000000>, 90 + <0x0 0xfc180000 0x0 0x1000>, 91 + <0x0 0xf5000000 0x0 0x2000>; 92 + reg-names = "dbi", "apb", "config"; 93 + bus-range = <0x0 0xff>; 94 + #address-cells = <3>; 95 + #size-cells = <2>; 96 + device_type = "pci"; 97 + phys = <&pcie_phy>; 98 + ranges = <0x02000000 0x0 0x00000000 99 + 0x0 0xf6000000 100 + 0x0 0x02000000>; 101 + num-lanes = <1>; 102 + #interrupt-cells = <1>; 103 + interrupts = <GIC_SPI 283 IRQ_TYPE_LEVEL_HIGH>; 104 + interrupt-names = "msi"; 105 + interrupt-map-mask = <0 0 0 7>; 106 + interrupt-map = <0x0 0 0 1 &gic GIC_SPI 282 IRQ_TYPE_LEVEL_HIGH>, 107 + <0x0 0 0 2 &gic GIC_SPI 283 IRQ_TYPE_LEVEL_HIGH>, 108 + <0x0 0 0 3 &gic GIC_SPI 284 IRQ_TYPE_LEVEL_HIGH>, 109 + <0x0 0 0 4 &gic GIC_SPI 285 IRQ_TYPE_LEVEL_HIGH>; 110 + reset-gpios = <&gpio7 0 0>; 111 + hisilicon,clken-gpios = <&gpio27 3 0>, <&gpio17 0 0>, <&gpio20 6 0>; 112 + pcie@0,0 { // Lane 0: PCIe switch: Bus 1, Device 0 113 + reg = <0 0 0 0 0>; 114 + compatible = "pciclass,0604"; 115 + device_type = "pci"; 116 + #address-cells = <3>; 117 + #size-cells = <2>; 118 + ranges; 119 + 120 + pcie@0,0 { // Lane 0: upstream 121 + reg = <0 0 0 0 0>; 122 + compatible = "pciclass,0604"; 123 + device_type = "pci"; 124 + #address-cells = <3>; 125 + #size-cells = <2>; 126 + ranges; 127 + 128 + pcie@1,0 { // Lane 4: M.2 129 + reg = <0x0800 0 0 0 0>; 130 + compatible = "pciclass,0604"; 131 + device_type = "pci"; 132 + reset-gpios = <&gpio3 1 0>; 133 + #address-cells = <3>; 134 + #size-cells = <2>; 135 + ranges; 136 + }; 137 + 138 + pcie@5,0 { // Lane 5: Mini PCIe 139 + reg = <0x2800 0 0 0 0>; 140 + compatible = "pciclass,0604"; 141 + device_type = "pci"; 142 + reset-gpios = <&gpio27 4 0 >; 143 + #address-cells = <3>; 144 + #size-cells = <2>; 145 + ranges; 146 + }; 147 + 148 + pcie@7,0 { // Lane 6: Ethernet 149 + reg = <0x03800 0 0 0 0>; 150 + compatible = "pciclass,0604"; 151 + device_type = "pci"; 152 + reset-gpios = <&gpio25 2 0 >; 153 + #address-cells = <3>; 154 + #size-cells = <2>; 155 + ranges; 156 + }; 157 + }; 158 + }; 92 159 }; 93 160 };