|
| 1 | +// SPDX-License-Identifier: GPL-2.0+ OR MIT |
| 2 | +/* |
| 3 | + * PCIe-GE Nodes present on both dies of a T6022 (M2 Ultra) and M2 Pro/Max but |
| 4 | + * only used on T6022 in the Mac Pro (2023). |
| 5 | + * |
| 6 | + * Copyright The Asahi Linux Contributors |
| 7 | + */ |
| 8 | + |
| 9 | + DIE_NODE(pcie_ge): pcie@1680000000 { |
| 10 | + compatible = "apple,t6020-pcie-ge", "apple,t6020-pcie"; |
| 11 | + device_type = "pci"; |
| 12 | + |
| 13 | + reg = <0x16 0x80000000 0x0 0x1000000>, /* config */ |
| 14 | + <0x16 0x91000000 0x0 0x4000>, /* rc */ |
| 15 | + <0x16 0x94008000 0x0 0x4000>, /* port0 */ |
| 16 | + <0x16 0x9e01c000 0x0 0x4000>, /* phy0 */ |
| 17 | + <0x16 0x9401c000 0x0 0x1000>; /* ltssm0 */ |
| 18 | + reg-names = "config", "rc", "port0", "phy0", "ltssm0"; |
| 19 | + |
| 20 | + interrupt-parent = <&aic>; |
| 21 | + interrupts = <AIC_IRQ DIE_NO 1356 IRQ_TYPE_LEVEL_HIGH>; |
| 22 | + |
| 23 | + msi-controller; |
| 24 | + msi-parent = <&DIE_NODE(pcie_ge)>; |
| 25 | + msi-ranges = <&aic AIC_IRQ DIE_NO 1672 IRQ_TYPE_EDGE_RISING 128>; |
| 26 | + |
| 27 | + iommu-map = <0x000 &DIE_NODE(pcie_ge_dart) 0 0>, |
| 28 | + <0x100 &DIE_NODE(pcie_ge_dart) 1 1>, |
| 29 | + <0x200 &DIE_NODE(pcie_ge_dart) 2 2>, |
| 30 | + <0x300 &DIE_NODE(pcie_ge_dart) 3 3>, |
| 31 | + <0x400 &DIE_NODE(pcie_ge_dart) 4 4>, |
| 32 | + <0x500 &DIE_NODE(pcie_ge_dart) 5 5>, |
| 33 | + <0x600 &DIE_NODE(pcie_ge_dart) 6 6>, |
| 34 | + <0x700 &DIE_NODE(pcie_ge_dart) 7 7>, |
| 35 | + <0x800 &DIE_NODE(pcie_ge_dart) 8 8>, |
| 36 | + <0x900 &DIE_NODE(pcie_ge_dart) 9 9>, |
| 37 | + <0xa00 &DIE_NODE(pcie_ge_dart) 10 10>, |
| 38 | + <0xb00 &DIE_NODE(pcie_ge_dart) 11 11>, |
| 39 | + <0xc00 &DIE_NODE(pcie_ge_dart) 12 12>, |
| 40 | + <0xd00 &DIE_NODE(pcie_ge_dart) 13 13>, |
| 41 | + <0xe00 &DIE_NODE(pcie_ge_dart) 14 14>; |
| 42 | + iommu-map-mask = <0xff00>; |
| 43 | + |
| 44 | + bus-range = <0 15>; |
| 45 | + #address-cells = <3>; |
| 46 | + #size-cells = <2>; |
| 47 | + ranges = <0x43000000 0x18 0x00000000 0x18 0x00000000 0x4 0x00000000>, |
| 48 | + <0x02000000 0x0 0x80000000 0x17 0x80000000 0x0 0x80000000>; |
| 49 | + |
| 50 | + power-domains = <&DIE_NODE(ps_apcie_ge_sys)>; |
| 51 | + pinctrl-0 = <&DIE_NODE(pcie_ge_pins)>; |
| 52 | + pinctrl-names = "default"; |
| 53 | + |
| 54 | + dma-coherent; |
| 55 | + |
| 56 | + status = "disabled"; |
| 57 | + |
| 58 | + DIE_NODE(port_ge00): pci@0,0 { |
| 59 | + device_type = "pci"; |
| 60 | + reg = <0x0 0x0 0x0 0x0 0x0>; |
| 61 | + reset-gpios = <&DIE_NODE(pinctrl_ap) 9 GPIO_ACTIVE_LOW>; |
| 62 | + |
| 63 | + #address-cells = <3>; |
| 64 | + #size-cells = <2>; |
| 65 | + ranges; |
| 66 | + |
| 67 | + interrupt-controller; |
| 68 | + #interrupt-cells = <1>; |
| 69 | + |
| 70 | + interrupt-map-mask = <0 0 0 7>; |
| 71 | + interrupt-map = <0 0 0 1 &DIE_NODE(port_ge00) 0 0 0 0>, |
| 72 | + <0 0 0 2 &DIE_NODE(port_ge00) 0 0 0 1>, |
| 73 | + <0 0 0 3 &DIE_NODE(port_ge00) 0 0 0 2>, |
| 74 | + <0 0 0 4 &DIE_NODE(port_ge00) 0 0 0 3>; |
| 75 | + }; |
| 76 | + }; |
| 77 | + |
| 78 | + DIE_NODE(pcie_ge_dart): iommu@1694000000 { |
| 79 | + compatible = "apple,t6020-dart", "apple,t8110-dart"; |
| 80 | + reg = <0x16 0x94000000 0x0 0x4000>; |
| 81 | + #iommu-cells = <1>; |
| 82 | + interrupt-parent = <&aic>; |
| 83 | + interrupts = <AIC_IRQ DIE_NO 1357 IRQ_TYPE_LEVEL_HIGH>; |
| 84 | + power-domains = <&DIE_NODE(ps_apcie_ge_sys)>; |
| 85 | + status = "disabled"; |
| 86 | + }; |
0 commit comments