diff mbox series

dt-bindings: ti,k3: Use common ti,k3-sci-common.yaml schema

Message ID 20230125221339.3057322-1-robh@kernel.org (mailing list archive)
State Handled Elsewhere
Headers show
Series dt-bindings: ti,k3: Use common ti,k3-sci-common.yaml schema | expand

Commit Message

Rob Herring (Arm) Jan. 25, 2023, 10:13 p.m. UTC
Instead of redefining the 'ti,sci' and 'ti,sci-dev-id' properties multiple
times, reference the common schema where they are defined. Most cases
using these properties already do this, just udma and ringacc need to be
fixed.

Signed-off-by: Rob Herring <robh@kernel.org>
---
 .../devicetree/bindings/dma/ti/k3-udma.yaml         |  9 +--------
 .../devicetree/bindings/soc/ti/k3-ringacc.yaml      | 13 ++++---------
 2 files changed, 5 insertions(+), 17 deletions(-)

Comments

Péter Ujfalusi Feb. 2, 2023, 7:46 p.m. UTC | #1
On 26/01/2023 00:13, Rob Herring wrote:
> Instead of redefining the 'ti,sci' and 'ti,sci-dev-id' properties multiple
> times, reference the common schema where they are defined. Most cases
> using these properties already do this, just udma and ringacc need to be
> fixed.

Acked-by: Peter Ujfalusi <peter.ujfalusi@gmail.com>

> 
> Signed-off-by: Rob Herring <robh@kernel.org>
> ---
>   .../devicetree/bindings/dma/ti/k3-udma.yaml         |  9 +--------
>   .../devicetree/bindings/soc/ti/k3-ringacc.yaml      | 13 ++++---------
>   2 files changed, 5 insertions(+), 17 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/dma/ti/k3-udma.yaml b/Documentation/devicetree/bindings/dma/ti/k3-udma.yaml
> index 7ff428ad3aae..97f6ae9b1236 100644
> --- a/Documentation/devicetree/bindings/dma/ti/k3-udma.yaml
> +++ b/Documentation/devicetree/bindings/dma/ti/k3-udma.yaml
> @@ -44,6 +44,7 @@ description: |
>   
>   allOf:
>     - $ref: "../dma-controller.yaml#"
> +  - $ref: /schemas/arm/keystone/ti,k3-sci-common.yaml#
>   
>   properties:
>     "#dma-cells":
> @@ -78,14 +79,6 @@ properties:
>   
>     msi-parent: true
>   
> -  ti,sci:
> -    description: phandle to TI-SCI compatible System controller node
> -    $ref: /schemas/types.yaml#/definitions/phandle
> -
> -  ti,sci-dev-id:
> -    description: TI-SCI device id of UDMAP
> -    $ref: /schemas/types.yaml#/definitions/uint32
> -
>     ti,ringacc:
>       description: phandle to the ring accelerator node
>       $ref: /schemas/types.yaml#/definitions/phandle
> diff --git a/Documentation/devicetree/bindings/soc/ti/k3-ringacc.yaml b/Documentation/devicetree/bindings/soc/ti/k3-ringacc.yaml
> index ddea3d41971d..22cf9002fee7 100644
> --- a/Documentation/devicetree/bindings/soc/ti/k3-ringacc.yaml
> +++ b/Documentation/devicetree/bindings/soc/ti/k3-ringacc.yaml
> @@ -25,6 +25,9 @@ description: |
>     The Ring Accelerator is a hardware module that is responsible for accelerating
>     management of the packet queues. The K3 SoCs can have more than one RA instances
>   
> +allOf:
> +  - $ref: /schemas/arm/keystone/ti,k3-sci-common.yaml#
> +
>   properties:
>     compatible:
>       items:
> @@ -54,14 +57,6 @@ properties:
>       $ref: /schemas/types.yaml#/definitions/uint32
>       description: TI-SCI RM subtype for GP ring range
>   
> -  ti,sci:
> -    $ref: /schemas/types.yaml#/definitions/phandle-array
> -    description: phandle on TI-SCI compatible System controller node
> -
> -  ti,sci-dev-id:
> -    $ref: /schemas/types.yaml#/definitions/uint32
> -    description: TI-SCI device id of the ring accelerator
> -
>   required:
>     - compatible
>     - reg
> @@ -72,7 +67,7 @@ required:
>     - ti,sci
>     - ti,sci-dev-id
>   
> -additionalProperties: false
> +unevaluatedProperties: false
>   
>   examples:
>     - |
Rob Herring (Arm) Feb. 2, 2023, 11:17 p.m. UTC | #2
On Wed, 25 Jan 2023 16:13:39 -0600, Rob Herring wrote:
> Instead of redefining the 'ti,sci' and 'ti,sci-dev-id' properties multiple
> times, reference the common schema where they are defined. Most cases
> using these properties already do this, just udma and ringacc need to be
> fixed.
> 
> Signed-off-by: Rob Herring <robh@kernel.org>
> ---
>  .../devicetree/bindings/dma/ti/k3-udma.yaml         |  9 +--------
>  .../devicetree/bindings/soc/ti/k3-ringacc.yaml      | 13 ++++---------
>  2 files changed, 5 insertions(+), 17 deletions(-)
> 

Applied, thanks!
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/dma/ti/k3-udma.yaml b/Documentation/devicetree/bindings/dma/ti/k3-udma.yaml
index 7ff428ad3aae..97f6ae9b1236 100644
--- a/Documentation/devicetree/bindings/dma/ti/k3-udma.yaml
+++ b/Documentation/devicetree/bindings/dma/ti/k3-udma.yaml
@@ -44,6 +44,7 @@  description: |
 
 allOf:
   - $ref: "../dma-controller.yaml#"
+  - $ref: /schemas/arm/keystone/ti,k3-sci-common.yaml#
 
 properties:
   "#dma-cells":
@@ -78,14 +79,6 @@  properties:
 
   msi-parent: true
 
-  ti,sci:
-    description: phandle to TI-SCI compatible System controller node
-    $ref: /schemas/types.yaml#/definitions/phandle
-
-  ti,sci-dev-id:
-    description: TI-SCI device id of UDMAP
-    $ref: /schemas/types.yaml#/definitions/uint32
-
   ti,ringacc:
     description: phandle to the ring accelerator node
     $ref: /schemas/types.yaml#/definitions/phandle
diff --git a/Documentation/devicetree/bindings/soc/ti/k3-ringacc.yaml b/Documentation/devicetree/bindings/soc/ti/k3-ringacc.yaml
index ddea3d41971d..22cf9002fee7 100644
--- a/Documentation/devicetree/bindings/soc/ti/k3-ringacc.yaml
+++ b/Documentation/devicetree/bindings/soc/ti/k3-ringacc.yaml
@@ -25,6 +25,9 @@  description: |
   The Ring Accelerator is a hardware module that is responsible for accelerating
   management of the packet queues. The K3 SoCs can have more than one RA instances
 
+allOf:
+  - $ref: /schemas/arm/keystone/ti,k3-sci-common.yaml#
+
 properties:
   compatible:
     items:
@@ -54,14 +57,6 @@  properties:
     $ref: /schemas/types.yaml#/definitions/uint32
     description: TI-SCI RM subtype for GP ring range
 
-  ti,sci:
-    $ref: /schemas/types.yaml#/definitions/phandle-array
-    description: phandle on TI-SCI compatible System controller node
-
-  ti,sci-dev-id:
-    $ref: /schemas/types.yaml#/definitions/uint32
-    description: TI-SCI device id of the ring accelerator
-
 required:
   - compatible
   - reg
@@ -72,7 +67,7 @@  required:
   - ti,sci
   - ti,sci-dev-id
 
-additionalProperties: false
+unevaluatedProperties: false
 
 examples:
   - |