diff mbox series

[v2,1/2] dt-bindings: remoteproc: mediatek: Fix optional reg-names for mtk,scp

Message ID 20220502192420.2548512-2-nfraprado@collabora.com (mailing list archive)
State Superseded
Headers show
Series Mediatek SCP dt-binding tweaks | expand

Commit Message

Nícolas F. R. A. Prado May 2, 2022, 7:24 p.m. UTC
The SCP has three memory regions: sram, l1tcm and cfg. Only sram is
required, the other two are optional. Fix the dt-binding so that the
optional regions can be omitted and passed in any order.

Also add the missing minItems to the reg property and update the
description.

Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>

---

(no changes since v1)

 .../devicetree/bindings/remoteproc/mtk,scp.yaml      | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

Comments

Krzysztof Kozlowski May 3, 2022, 12:20 p.m. UTC | #1
On 02/05/2022 21:24, Nícolas F. R. A. Prado wrote:
> The SCP has three memory regions: sram, l1tcm and cfg. Only sram is
> required, the other two are optional. Fix the dt-binding so that the
> optional regions can be omitted and passed in any order.

I commented for v1 - order is strict, so no for this change.

> 
> Also add the missing minItems to the reg property and update the
> description.
> 
> Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
> 
> ---
> 
> (no changes since v1)
> 
>  .../devicetree/bindings/remoteproc/mtk,scp.yaml      | 12 +++++++++---
>  1 file changed, 9 insertions(+), 3 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
> index 823a236242de..ec9ddeb6ca2c 100644
> --- a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
> +++ b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
> @@ -24,14 +24,20 @@ properties:
>    reg:
>      description:
>        Should contain the address ranges for memory regions SRAM, CFG, and
> -      L1TCM.
> +      L1TCM. Only SRAM is required, while CFG and L1TCM are optional.
> +    minItems: 1
>      maxItems: 3
>  
>    reg-names:
> +    minItems: 1
>      items:
>        - const: sram
> -      - const: cfg
> -      - const: l1tcm
> +      - enum:
> +          - l1tcm
> +          - cfg
> +      - enum:
> +          - l1tcm
> +          - cfg

Nope.

>  
>    clocks:
>      description:


Best regards,
Krzysztof
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
index 823a236242de..ec9ddeb6ca2c 100644
--- a/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
+++ b/Documentation/devicetree/bindings/remoteproc/mtk,scp.yaml
@@ -24,14 +24,20 @@  properties:
   reg:
     description:
       Should contain the address ranges for memory regions SRAM, CFG, and
-      L1TCM.
+      L1TCM. Only SRAM is required, while CFG and L1TCM are optional.
+    minItems: 1
     maxItems: 3
 
   reg-names:
+    minItems: 1
     items:
       - const: sram
-      - const: cfg
-      - const: l1tcm
+      - enum:
+          - l1tcm
+          - cfg
+      - enum:
+          - l1tcm
+          - cfg
 
   clocks:
     description: