[v14,01/22] dt-bindings: PCI: Add PLDA XpressRICH PCIe host common properties

Message ID 20240108110612.19048-2-minda.chen@starfivetech.com
State New
Headers
Series Refactoring Microchip PCIe driver and add StarFive PCIe |

Commit Message

Minda Chen Jan. 8, 2024, 11:05 a.m. UTC
  Add PLDA XpressRICH PCIe host common properties dt-binding doc.
PolarFire PCIe host using PLDA IP. Move common properties from Microchip
PolarFire PCIe host to PLDA files.

Signed-off-by: Minda Chen <minda.chen@starfivetech.com>
Reviewed-by: Hal Feng <hal.feng@starfivetech.com>
Reviewed-by: Conor Dooley <conor.dooley@microchip.com>
Reviewed-by: Rob Herring <robh@kernel.org>
Tested-by: John Clark <inindev@gmail.com>
---
 .../bindings/pci/microchip,pcie-host.yaml     | 55 +-------------
 .../pci/plda,xpressrich3-axi-common.yaml      | 75 +++++++++++++++++++
 2 files changed, 76 insertions(+), 54 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/pci/plda,xpressrich3-axi-common.yaml
  

Comments

Minda Chen Jan. 8, 2024, 11:21 a.m. UTC | #1
> 主题: [PATCH v14 01/22] dt-bindings: PCI: Add PLDA XpressRICH PCIe host
> common properties
> 
Add Tomas
> Add PLDA XpressRICH PCIe host common properties dt-binding doc.
> PolarFire PCIe host using PLDA IP. Move common properties from Microchip
> PolarFire PCIe host to PLDA files.
> 
> Signed-off-by: Minda Chen <minda.chen@starfivetech.com>
> Reviewed-by: Hal Feng <hal.feng@starfivetech.com>
> Reviewed-by: Conor Dooley <conor.dooley@microchip.com>
> Reviewed-by: Rob Herring <robh@kernel.org>
> Tested-by: John Clark <inindev@gmail.com>
> ---
>  .../bindings/pci/microchip,pcie-host.yaml     | 55 +-------------
>  .../pci/plda,xpressrich3-axi-common.yaml      | 75 +++++++++++++++++++
>  2 files changed, 76 insertions(+), 54 deletions(-)  create mode 100644
> Documentation/devicetree/bindings/pci/plda,xpressrich3-axi-common.yaml
> 
> diff --git a/Documentation/devicetree/bindings/pci/microchip,pcie-host.yaml
> b/Documentation/devicetree/bindings/pci/microchip,pcie-host.yaml
> index f7a3c2636355..7c2d51221f65 100644
> --- a/Documentation/devicetree/bindings/pci/microchip,pcie-host.yaml
> +++ b/Documentation/devicetree/bindings/pci/microchip,pcie-host.yaml
> @@ -10,21 +10,13 @@ maintainers:
>    - Daire McNamara <daire.mcnamara@microchip.com>
> 
>  allOf:
> -  - $ref: /schemas/pci/pci-bus.yaml#
> +  - $ref: plda,xpressrich3-axi-common.yaml#
>    - $ref: /schemas/interrupt-controller/msi-controller.yaml#
> 
>  properties:
>    compatible:
>      const: microchip,pcie-host-1.0 # PolarFire
> 
> -  reg:
> -    maxItems: 2
> -
> -  reg-names:
> -    items:
> -      - const: cfg
> -      - const: apb
> -
>    clocks:
>      description:
>        Fabric Interface Controllers, FICs, are the interface between the FPGA
> @@ -52,18 +44,6 @@ properties:
>      items:
>        pattern: '^fic[0-3]$'
> 
> -  interrupts:
> -    minItems: 1
> -    items:
> -      - description: PCIe host controller
> -      - description: builtin MSI controller
> -
> -  interrupt-names:
> -    minItems: 1
> -    items:
> -      - const: pcie
> -      - const: msi
> -
>    ranges:
>      maxItems: 1
> 
> @@ -71,39 +51,6 @@ properties:
>      minItems: 1
>      maxItems: 6
> 
> -  msi-controller:
> -    description: Identifies the node as an MSI controller.
> -
> -  msi-parent:
> -    description: MSI controller the device is capable of using.
> -
> -  interrupt-controller:
> -    type: object
> -    properties:
> -      '#address-cells':
> -        const: 0
> -
> -      '#interrupt-cells':
> -        const: 1
> -
> -      interrupt-controller: true
> -
> -    required:
> -      - '#address-cells'
> -      - '#interrupt-cells'
> -      - interrupt-controller
> -
> -    additionalProperties: false
> -
> -required:
> -  - reg
> -  - reg-names
> -  - "#interrupt-cells"
> -  - interrupts
> -  - interrupt-map-mask
> -  - interrupt-map
> -  - msi-controller
> -
>  unevaluatedProperties: false
> 
>  examples:
> diff --git
> a/Documentation/devicetree/bindings/pci/plda,xpressrich3-axi-common.yaml
> b/Documentation/devicetree/bindings/pci/plda,xpressrich3-axi-common.yaml
> new file mode 100644
> index 000000000000..31bb17b11e58
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/pci/plda,xpressrich3-axi-common.
> +++ yaml
> @@ -0,0 +1,75 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) %YAML 1.2
> +---
> +$id:
> +http://devicetree.org/schemas/pci/plda,xpressrich3-axi-common.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: PLDA XpressRICH PCIe host common properties
> +
> +maintainers:
> +  - Daire McNamara <daire.mcnamara@microchip.com>
> +  - Kevin Xie <kevin.xie@starfivetech.com>
> +
> +description:
> +  Generic PLDA XpressRICH PCIe host common properties.
> +
> +allOf:
> +  - $ref: /schemas/pci/pci-bus.yaml#
> +
> +properties:
> +  reg:
> +    maxItems: 2
> +
> +  reg-names:
> +    items:
> +      - const: cfg
> +      - const: apb
> +
> +  interrupts:
> +    minItems: 1
> +    items:
> +      - description: PCIe host controller
> +      - description: builtin MSI controller
> +
> +  interrupt-names:
> +    minItems: 1
> +    items:
> +      - const: pcie
> +      - const: msi
> +
> +  msi-controller:
> +    description: Identifies the node as an MSI controller.
> +
> +  msi-parent:
> +    description: MSI controller the device is capable of using.
> +
> +  interrupt-controller:
> +    type: object
> +    properties:
> +      '#address-cells':
> +        const: 0
> +
> +      '#interrupt-cells':
> +        const: 1
> +
> +      interrupt-controller: true
> +
> +    required:
> +      - '#address-cells'
> +      - '#interrupt-cells'
> +      - interrupt-controller
> +
> +    additionalProperties: false
> +
> +required:
> +  - reg
> +  - reg-names
> +  - interrupts
> +  - msi-controller
> +  - "#interrupt-cells"
> +  - interrupt-map-mask
> +  - interrupt-map
> +
> +additionalProperties: true
> +
> +...
> --
> 2.17.1
  

Patch

diff --git a/Documentation/devicetree/bindings/pci/microchip,pcie-host.yaml b/Documentation/devicetree/bindings/pci/microchip,pcie-host.yaml
index f7a3c2636355..7c2d51221f65 100644
--- a/Documentation/devicetree/bindings/pci/microchip,pcie-host.yaml
+++ b/Documentation/devicetree/bindings/pci/microchip,pcie-host.yaml
@@ -10,21 +10,13 @@  maintainers:
   - Daire McNamara <daire.mcnamara@microchip.com>
 
 allOf:
-  - $ref: /schemas/pci/pci-bus.yaml#
+  - $ref: plda,xpressrich3-axi-common.yaml#
   - $ref: /schemas/interrupt-controller/msi-controller.yaml#
 
 properties:
   compatible:
     const: microchip,pcie-host-1.0 # PolarFire
 
-  reg:
-    maxItems: 2
-
-  reg-names:
-    items:
-      - const: cfg
-      - const: apb
-
   clocks:
     description:
       Fabric Interface Controllers, FICs, are the interface between the FPGA
@@ -52,18 +44,6 @@  properties:
     items:
       pattern: '^fic[0-3]$'
 
-  interrupts:
-    minItems: 1
-    items:
-      - description: PCIe host controller
-      - description: builtin MSI controller
-
-  interrupt-names:
-    minItems: 1
-    items:
-      - const: pcie
-      - const: msi
-
   ranges:
     maxItems: 1
 
@@ -71,39 +51,6 @@  properties:
     minItems: 1
     maxItems: 6
 
-  msi-controller:
-    description: Identifies the node as an MSI controller.
-
-  msi-parent:
-    description: MSI controller the device is capable of using.
-
-  interrupt-controller:
-    type: object
-    properties:
-      '#address-cells':
-        const: 0
-
-      '#interrupt-cells':
-        const: 1
-
-      interrupt-controller: true
-
-    required:
-      - '#address-cells'
-      - '#interrupt-cells'
-      - interrupt-controller
-
-    additionalProperties: false
-
-required:
-  - reg
-  - reg-names
-  - "#interrupt-cells"
-  - interrupts
-  - interrupt-map-mask
-  - interrupt-map
-  - msi-controller
-
 unevaluatedProperties: false
 
 examples:
diff --git a/Documentation/devicetree/bindings/pci/plda,xpressrich3-axi-common.yaml b/Documentation/devicetree/bindings/pci/plda,xpressrich3-axi-common.yaml
new file mode 100644
index 000000000000..31bb17b11e58
--- /dev/null
+++ b/Documentation/devicetree/bindings/pci/plda,xpressrich3-axi-common.yaml
@@ -0,0 +1,75 @@ 
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/pci/plda,xpressrich3-axi-common.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: PLDA XpressRICH PCIe host common properties
+
+maintainers:
+  - Daire McNamara <daire.mcnamara@microchip.com>
+  - Kevin Xie <kevin.xie@starfivetech.com>
+
+description:
+  Generic PLDA XpressRICH PCIe host common properties.
+
+allOf:
+  - $ref: /schemas/pci/pci-bus.yaml#
+
+properties:
+  reg:
+    maxItems: 2
+
+  reg-names:
+    items:
+      - const: cfg
+      - const: apb
+
+  interrupts:
+    minItems: 1
+    items:
+      - description: PCIe host controller
+      - description: builtin MSI controller
+
+  interrupt-names:
+    minItems: 1
+    items:
+      - const: pcie
+      - const: msi
+
+  msi-controller:
+    description: Identifies the node as an MSI controller.
+
+  msi-parent:
+    description: MSI controller the device is capable of using.
+
+  interrupt-controller:
+    type: object
+    properties:
+      '#address-cells':
+        const: 0
+
+      '#interrupt-cells':
+        const: 1
+
+      interrupt-controller: true
+
+    required:
+      - '#address-cells'
+      - '#interrupt-cells'
+      - interrupt-controller
+
+    additionalProperties: false
+
+required:
+  - reg
+  - reg-names
+  - interrupts
+  - msi-controller
+  - "#interrupt-cells"
+  - interrupt-map-mask
+  - interrupt-map
+
+additionalProperties: true
+
+...