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

dt-bindings: PCI: mobiveil: Convert mobiveil-pcie.txt to YAML

Convert device tree binding document mobiveil-pcie.txt to YAML format
and merge layerscape-pcie-gen4.txt into this file.

Additional changes:

- interrupt-names: "aer", "pme", "intr", which align order in examples.

- reg-names: reorder as csr_axi_slave, config_axi_slave to match
layerscape-pcie-gen4 and existing Layerscape DTS users.

Fix below CHECK_DTBS warning:

arch/arm64/boot/dts/freescale/fsl-lx2160a-qds.dtb: /soc/pcie@3400000: failed to match any schema with compatible: ['fsl,lx2160a-pcie']

Link: https://lore.kernel.org/r/20241211171318.4129818-1-Frank.Li@nxp.com
Signed-off-by: Frank Li <Frank.Li@nxp.com>
Signed-off-by: Lorenzo Pieralisi <lpieralisi@kernel.org>
[kwilczynski: commit log]
Signed-off-by: Krzysztof Wilczyński <kwilczynski@kernel.org>
[bhelgaas: fix typos, whitespace, consistent bus-range usage]
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

authored by

Frank Li and committed by
Bjorn Helgaas
b02cfbd9 40384c84

+174 -126
-52
Documentation/devicetree/bindings/pci/layerscape-pcie-gen4.txt
··· 1 - NXP Layerscape PCIe Gen4 controller 2 - 3 - This PCIe controller is based on the Mobiveil PCIe IP and thus inherits all 4 - the common properties defined in mobiveil-pcie.txt. 5 - 6 - Required properties: 7 - - compatible: should contain the platform identifier such as: 8 - "fsl,lx2160a-pcie" 9 - - reg: base addresses and lengths of the PCIe controller register blocks. 10 - "csr_axi_slave": Bridge config registers 11 - "config_axi_slave": PCIe controller registers 12 - - interrupts: A list of interrupt outputs of the controller. Must contain an 13 - entry for each entry in the interrupt-names property. 14 - - interrupt-names: It could include the following entries: 15 - "intr": The interrupt that is asserted for controller interrupts 16 - "aer": Asserted for aer interrupt when chip support the aer interrupt with 17 - none MSI/MSI-X/INTx mode,but there is interrupt line for aer. 18 - "pme": Asserted for pme interrupt when chip support the pme interrupt with 19 - none MSI/MSI-X/INTx mode,but there is interrupt line for pme. 20 - - dma-coherent: Indicates that the hardware IP block can ensure the coherency 21 - of the data transferred from/to the IP block. This can avoid the software 22 - cache flush/invalid actions, and improve the performance significantly. 23 - - msi-parent : See the generic MSI binding described in 24 - Documentation/devicetree/bindings/interrupt-controller/msi.txt. 25 - 26 - Example: 27 - 28 - pcie@3400000 { 29 - compatible = "fsl,lx2160a-pcie"; 30 - reg = <0x00 0x03400000 0x0 0x00100000 /* controller registers */ 31 - 0x80 0x00000000 0x0 0x00001000>; /* configuration space */ 32 - reg-names = "csr_axi_slave", "config_axi_slave"; 33 - interrupts = <GIC_SPI 108 IRQ_TYPE_LEVEL_HIGH>, /* AER interrupt */ 34 - <GIC_SPI 108 IRQ_TYPE_LEVEL_HIGH>, /* PME interrupt */ 35 - <GIC_SPI 108 IRQ_TYPE_LEVEL_HIGH>; /* controller interrupt */ 36 - interrupt-names = "aer", "pme", "intr"; 37 - #address-cells = <3>; 38 - #size-cells = <2>; 39 - device_type = "pci"; 40 - apio-wins = <8>; 41 - ppio-wins = <8>; 42 - dma-coherent; 43 - bus-range = <0x0 0xff>; 44 - msi-parent = <&its>; 45 - ranges = <0x82000000 0x0 0x40000000 0x80 0x40000000 0x0 0x40000000>; 46 - #interrupt-cells = <1>; 47 - interrupt-map-mask = <0 0 0 7>; 48 - interrupt-map = <0000 0 0 1 &gic 0 0 GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>, 49 - <0000 0 0 2 &gic 0 0 GIC_SPI 110 IRQ_TYPE_LEVEL_HIGH>, 50 - <0000 0 0 3 &gic 0 0 GIC_SPI 111 IRQ_TYPE_LEVEL_HIGH>, 51 - <0000 0 0 4 &gic 0 0 GIC_SPI 112 IRQ_TYPE_LEVEL_HIGH>; 52 - };
+173
Documentation/devicetree/bindings/pci/mbvl,gpex40-pcie.yaml
··· 1 + # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/pci/mbvl,gpex40-pcie.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: Mobiveil AXI PCIe Host Bridge 8 + 9 + maintainers: 10 + - Frank Li <Frank Li@nxp.com> 11 + 12 + description: 13 + Mobiveil's GPEX 4.0 is a PCIe Gen4 host bridge IP. This configurable IP 14 + has up to 8 outbound and inbound windows for address translation. 15 + 16 + NXP Layerscape PCIe Gen4 controller (Deprecated) base on Mobiveil's GPEX 4.0. 17 + 18 + properties: 19 + compatible: 20 + enum: 21 + - fsl,lx2160a-pcie 22 + - mbvl,gpex40-pcie 23 + 24 + reg: 25 + items: 26 + - description: PCIe controller registers 27 + - description: Bridge config registers 28 + - description: GPIO registers to control slot power 29 + - description: MSI registers 30 + minItems: 2 31 + 32 + reg-names: 33 + items: 34 + - const: csr_axi_slave 35 + - const: config_axi_slave 36 + - const: gpio_slave 37 + - const: apb_csr 38 + minItems: 2 39 + 40 + apio-wins: 41 + $ref: /schemas/types.yaml#/definitions/uint32 42 + description: | 43 + number of requested APIO outbound windows 44 + 1. Config window 45 + 2. Memory window 46 + default: 2 47 + maximum: 256 48 + 49 + ppio-wins: 50 + $ref: /schemas/types.yaml#/definitions/uint32 51 + description: number of requested PPIO inbound windows 52 + default: 1 53 + maximum: 256 54 + 55 + interrupt-controller: true 56 + 57 + "#interrupt-cells": 58 + const: 1 59 + 60 + interrupts: 61 + minItems: 1 62 + maxItems: 3 63 + 64 + interrupt-names: 65 + minItems: 1 66 + maxItems: 3 67 + 68 + dma-coherent: true 69 + 70 + msi-parent: true 71 + 72 + required: 73 + - compatible 74 + - reg 75 + - reg-names 76 + 77 + allOf: 78 + - $ref: /schemas/pci/pci-host-bridge.yaml# 79 + - if: 80 + properties: 81 + compatible: 82 + enum: 83 + - fsl,lx2160a-pcie 84 + then: 85 + properties: 86 + reg: 87 + maxItems: 2 88 + 89 + reg-names: 90 + maxItems: 2 91 + 92 + interrupts: 93 + minItems: 3 94 + 95 + interrupt-names: 96 + items: 97 + - const: aer 98 + - const: pme 99 + - const: intr 100 + else: 101 + properties: 102 + dma-coherent: false 103 + msi-parent: false 104 + interrupts: 105 + maxItems: 1 106 + interrupt-names: false 107 + 108 + unevaluatedProperties: false 109 + 110 + examples: 111 + - | 112 + #include <dt-bindings/interrupt-controller/arm-gic.h> 113 + 114 + pcie@b0000000 { 115 + compatible = "mbvl,gpex40-pcie"; 116 + reg = <0xb0000000 0x00010000>, 117 + <0xa0000000 0x00001000>, 118 + <0xff000000 0x00200000>, 119 + <0xb0010000 0x00001000>; 120 + reg-names = "csr_axi_slave", 121 + "config_axi_slave", 122 + "gpio_slave", 123 + "apb_csr"; 124 + ranges = <0x83000000 0 0x00000000 0xa8000000 0 0x8000000>; 125 + #address-cells = <3>; 126 + #size-cells = <2>; 127 + device_type = "pci"; 128 + apio-wins = <2>; 129 + ppio-wins = <1>; 130 + bus-range = <0x00 0xff>; 131 + interrupt-controller; 132 + #interrupt-cells = <1>; 133 + interrupt-parent = <&gic>; 134 + interrupts = <GIC_SPI 89 IRQ_TYPE_LEVEL_HIGH>; 135 + interrupt-map-mask = <0 0 0 7>; 136 + interrupt-map = <0 0 0 0 &pci_express 0>, 137 + <0 0 0 1 &pci_express 1>, 138 + <0 0 0 2 &pci_express 2>, 139 + <0 0 0 3 &pci_express 3>; 140 + }; 141 + 142 + - | 143 + #include <dt-bindings/interrupt-controller/arm-gic.h> 144 + 145 + soc { 146 + #address-cells = <2>; 147 + #size-cells = <2>; 148 + pcie@3400000 { 149 + compatible = "fsl,lx2160a-pcie"; 150 + reg = <0x00 0x03400000 0x0 0x00100000 /* controller registers */ 151 + 0x80 0x00000000 0x0 0x00001000>; /* configuration space */ 152 + reg-names = "csr_axi_slave", "config_axi_slave"; 153 + ranges = <0x82000000 0x0 0x40000000 0x80 0x40000000 0x0 0x40000000>; 154 + interrupts = <GIC_SPI 108 IRQ_TYPE_LEVEL_HIGH>, /* AER interrupt */ 155 + <GIC_SPI 108 IRQ_TYPE_LEVEL_HIGH>, /* PME interrupt */ 156 + <GIC_SPI 108 IRQ_TYPE_LEVEL_HIGH>; /* controller interrupt */ 157 + interrupt-names = "aer", "pme", "intr"; 158 + #address-cells = <3>; 159 + #size-cells = <2>; 160 + device_type = "pci"; 161 + apio-wins = <8>; 162 + ppio-wins = <8>; 163 + dma-coherent; 164 + bus-range = <0x00 0xff>; 165 + msi-parent = <&its>; 166 + #interrupt-cells = <1>; 167 + interrupt-map-mask = <0 0 0 7>; 168 + interrupt-map = <0000 0 0 1 &gic 0 0 GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>, 169 + <0000 0 0 2 &gic 0 0 GIC_SPI 110 IRQ_TYPE_LEVEL_HIGH>, 170 + <0000 0 0 3 &gic 0 0 GIC_SPI 111 IRQ_TYPE_LEVEL_HIGH>, 171 + <0000 0 0 4 &gic 0 0 GIC_SPI 112 IRQ_TYPE_LEVEL_HIGH>; 172 + }; 173 + };
-72
Documentation/devicetree/bindings/pci/mobiveil-pcie.txt
··· 1 - * Mobiveil AXI PCIe Root Port Bridge DT description 2 - 3 - Mobiveil's GPEX 4.0 is a PCIe Gen4 root port bridge IP. This configurable IP 4 - has up to 8 outbound and inbound windows for the address translation. 5 - 6 - Required properties: 7 - - #address-cells: Address representation for root ports, set to <3> 8 - - #size-cells: Size representation for root ports, set to <2> 9 - - #interrupt-cells: specifies the number of cells needed to encode an 10 - interrupt source. The value must be 1. 11 - - compatible: Should contain "mbvl,gpex40-pcie" 12 - - reg: Should contain PCIe registers location and length 13 - Mandatory: 14 - "config_axi_slave": PCIe controller registers 15 - "csr_axi_slave" : Bridge config registers 16 - Optional: 17 - "gpio_slave" : GPIO registers to control slot power 18 - "apb_csr" : MSI registers 19 - 20 - - device_type: must be "pci" 21 - - apio-wins : number of requested apio outbound windows 22 - default 2 outbound windows are configured - 23 - 1. Config window 24 - 2. Memory window 25 - - ppio-wins : number of requested ppio inbound windows 26 - default 1 inbound memory window is configured. 27 - - bus-range: PCI bus numbers covered 28 - - interrupt-controller: identifies the node as an interrupt controller 29 - - #interrupt-cells: specifies the number of cells needed to encode an 30 - interrupt source. The value must be 1. 31 - - interrupts: The interrupt line of the PCIe controller 32 - last cell of this field is set to 4 to 33 - denote it as IRQ_TYPE_LEVEL_HIGH type interrupt. 34 - - interrupt-map-mask, 35 - interrupt-map: standard PCI properties to define the mapping of the 36 - PCI interface to interrupt numbers. 37 - - ranges: ranges for the PCI memory regions (I/O space region is not 38 - supported by hardware) 39 - Please refer to the standard PCI bus binding document for a more 40 - detailed explanation 41 - 42 - 43 - Example: 44 - ++++++++ 45 - pcie0: pcie@a0000000 { 46 - #address-cells = <3>; 47 - #size-cells = <2>; 48 - compatible = "mbvl,gpex40-pcie"; 49 - reg = <0xa0000000 0x00001000>, 50 - <0xb0000000 0x00010000>, 51 - <0xff000000 0x00200000>, 52 - <0xb0010000 0x00001000>; 53 - reg-names = "config_axi_slave", 54 - "csr_axi_slave", 55 - "gpio_slave", 56 - "apb_csr"; 57 - device_type = "pci"; 58 - apio-wins = <2>; 59 - ppio-wins = <1>; 60 - bus-range = <0x00000000 0x000000ff>; 61 - interrupt-controller; 62 - interrupt-parent = <&gic>; 63 - #interrupt-cells = <1>; 64 - interrupts = < 0 89 4 >; 65 - interrupt-map-mask = <0 0 0 7>; 66 - interrupt-map = <0 0 0 0 &pci_express 0>, 67 - <0 0 0 1 &pci_express 1>, 68 - <0 0 0 2 &pci_express 2>, 69 - <0 0 0 3 &pci_express 3>; 70 - ranges = < 0x83000000 0 0x00000000 0xa8000000 0 0x8000000>; 71 - 72 - };
+1 -2
MAINTAINERS
··· 17901 17901 M: Hou Zhiqiang <Zhiqiang.Hou@nxp.com> 17902 17902 L: linux-pci@vger.kernel.org 17903 17903 S: Supported 17904 - F: Documentation/devicetree/bindings/pci/mobiveil-pcie.txt 17904 + F: Documentation/devicetree/bindings/pci/mbvl,gpex40-pcie.yaml 17905 17905 F: drivers/pci/controller/mobiveil/pcie-mobiveil* 17906 17906 17907 17907 PCI DRIVER FOR MVEBU (Marvell Armada 370 and Armada XP SOC support) ··· 17925 17925 L: linux-pci@vger.kernel.org 17926 17926 L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) 17927 17927 S: Maintained 17928 - F: Documentation/devicetree/bindings/pci/layerscape-pcie-gen4.txt 17929 17928 F: drivers/pci/controller/mobiveil/pcie-layerscape-gen4.c 17930 17929 17931 17930 PCI DRIVER FOR PLDA PCIE IP