diff mbox series

[1/2] ASoC: dt-bindings: add stm32mp25 support for sai

Message ID 20241107155143.1340523-2-olivier.moysan@foss.st.com (mailing list archive)
State Accepted
Commit 8509bb1f11a1fed710271631c2e06fd66452f510
Headers show
Series ASoC: stm32: sai: add stm32mp25 support | expand

Commit Message

Olivier Moysan Nov. 7, 2024, 3:51 p.m. UTC
Add STM32MP25 support for STM32 SAI peripheral,
through "st,stm32mp25-sai" compatible.

Signed-off-by: Olivier Moysan <olivier.moysan@foss.st.com>
---
 .../bindings/sound/st,stm32-sai.yaml          | 26 ++++++++++++++++++-
 1 file changed, 25 insertions(+), 1 deletion(-)

Comments

Krzysztof Kozlowski Nov. 8, 2024, 12:32 p.m. UTC | #1
On Thu, Nov 07, 2024 at 04:51:41PM +0100, Olivier Moysan wrote:
> Add STM32MP25 support for STM32 SAI peripheral,
> through "st,stm32mp25-sai" compatible.
> 
> Signed-off-by: Olivier Moysan <olivier.moysan@foss.st.com>
> ---
>  .../bindings/sound/st,stm32-sai.yaml          | 26 ++++++++++++++++++-
>  1 file changed, 25 insertions(+), 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/sound/st,stm32-sai.yaml b/Documentation/devicetree/bindings/sound/st,stm32-sai.yaml
> index 68f97b462598..4a7129d0b157 100644
> --- a/Documentation/devicetree/bindings/sound/st,stm32-sai.yaml
> +++ b/Documentation/devicetree/bindings/sound/st,stm32-sai.yaml
> @@ -20,6 +20,7 @@ properties:
>      enum:
>        - st,stm32f4-sai
>        - st,stm32h7-sai
> +      - st,stm32mp25-sai
>  
>    reg:
>      items:
> @@ -43,9 +44,11 @@ properties:
>      const: 1
>  
>    clocks:
> +    minItems: 1
>      maxItems: 3
>  
>    clock-names:
> +    minItems: 1

This actually fixes the binding because it lacked minItems before :/

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

Best regards,
Krzysztof
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/sound/st,stm32-sai.yaml b/Documentation/devicetree/bindings/sound/st,stm32-sai.yaml
index 68f97b462598..4a7129d0b157 100644
--- a/Documentation/devicetree/bindings/sound/st,stm32-sai.yaml
+++ b/Documentation/devicetree/bindings/sound/st,stm32-sai.yaml
@@ -20,6 +20,7 @@  properties:
     enum:
       - st,stm32f4-sai
       - st,stm32h7-sai
+      - st,stm32mp25-sai
 
   reg:
     items:
@@ -43,9 +44,11 @@  properties:
     const: 1
 
   clocks:
+    minItems: 1
     maxItems: 3
 
   clock-names:
+    minItems: 1
     maxItems: 3
 
   access-controllers:
@@ -156,7 +159,13 @@  allOf:
           items:
             - const: x8k
             - const: x11k
-    else:
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            const: st,stm32mph7-sai
+    then:
       properties:
         clocks:
           items:
@@ -170,6 +179,21 @@  allOf:
             - const: x8k
             - const: x11k
 
+  - if:
+      properties:
+        compatible:
+          contains:
+            const: st,stm32mp25-sai
+    then:
+      properties:
+        clocks:
+          items:
+            - description: pclk feeds the peripheral bus interface.
+
+        clock-names:
+          items:
+            - const: pclk
+
 additionalProperties: false
 
 examples: