diff mbox series

[3/4] dt-bindings: arm: mediatek: Add missing power-domains property

Message ID 20221215120016.26611-4-allen-kh.cheng@mediatek.com (mailing list archive)
State New, archived
Headers show
Series Add ADSP power domains controller support for MT8192 | expand

Commit Message

Allen-KH Cheng Dec. 15, 2022, noon UTC
The "mediatek,mt8192-scp_adsp" binding requires a power domain to be
specified.

Fixes: 4a803990aeb1 ("dt-bindings: ARM: Mediatek: Add new document bindings of MT8192 clock")
Signed-off-by: Allen-KH Cheng <allen-kh.cheng@mediatek.com>
---
 .../arm/mediatek/mediatek,mt8192-clock.yaml     | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

Comments

Krzysztof Kozlowski Dec. 16, 2022, 10:58 a.m. UTC | #1
On 15/12/2022 13:00, Allen-KH Cheng wrote:
> The "mediatek,mt8192-scp_adsp" binding requires a power domain to be
> specified.
> 
> Fixes: 4a803990aeb1 ("dt-bindings: ARM: Mediatek: Add new document bindings of MT8192 clock")
> Signed-off-by: Allen-KH Cheng <allen-kh.cheng@mediatek.com>
> ---
>  .../arm/mediatek/mediatek,mt8192-clock.yaml     | 17 +++++++++++++++++
>  1 file changed, 17 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/arm/mediatek/mediatek,mt8192-clock.yaml b/Documentation/devicetree/bindings/arm/mediatek/mediatek,mt8192-clock.yaml
> index b57cc2e69efb..cbedef114103 100644
> --- a/Documentation/devicetree/bindings/arm/mediatek/mediatek,mt8192-clock.yaml
> +++ b/Documentation/devicetree/bindings/arm/mediatek/mediatek,mt8192-clock.yaml
> @@ -40,6 +40,9 @@ properties:
>    reg:
>      maxItems: 1
>  
> +  power-domains:
> +    maxItems: 1
> +
>    '#clock-cells':
>      const: 1
>  
> @@ -49,11 +52,25 @@ required:
>  
>  additionalProperties: false
>  
> +allOf:

allOf goes just before additionalProperties.

> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - mediatek,mt8192-scp_adsp

For the future: please don't use underscores in compatibles.

> +    then:
> +      required:
> +        - power-domains
> +
>  examples:
>    - |
> +    #include <dt-bindings/power/mt8192-power.h>
> +
>      scp_adsp: clock-controller@10720000 {
>          compatible = "mediatek,mt8192-scp_adsp";
>          reg = <0x10720000 0x1000>;
> +        power-domains = <&spm MT8192_POWER_DOMAIN_ADSP>;
>          #clock-cells = <1>;
>      };
>  

Best regards,
Krzysztof
Allen-KH Cheng Dec. 20, 2022, 12:49 p.m. UTC | #2
Hi Krzysztof,

Thanks for the reminder.

On Fri, 2022-12-16 at 11:58 +0100, Krzysztof Kozlowski wrote:
> On 15/12/2022 13:00, Allen-KH Cheng wrote:
> > The "mediatek,mt8192-scp_adsp" binding requires a power domain to
> > be
> > specified.
> > 
> > Fixes: 4a803990aeb1 ("dt-bindings: ARM: Mediatek: Add new document
> > bindings of MT8192 clock")
> > Signed-off-by: Allen-KH Cheng <allen-kh.cheng@mediatek.com>
> > ---
> >  .../arm/mediatek/mediatek,mt8192-clock.yaml     | 17
> > +++++++++++++++++
> >  1 file changed, 17 insertions(+)
> > 
> > diff --git
> > a/Documentation/devicetree/bindings/arm/mediatek/mediatek,mt8192-
> > clock.yaml
> > b/Documentation/devicetree/bindings/arm/mediatek/mediatek,mt8192-
> > clock.yaml
> > index b57cc2e69efb..cbedef114103 100644
> > ---
> > a/Documentation/devicetree/bindings/arm/mediatek/mediatek,mt8192-
> > clock.yaml
> > +++
> > b/Documentation/devicetree/bindings/arm/mediatek/mediatek,mt8192-
> > clock.yaml
> > @@ -40,6 +40,9 @@ properties:
> >    reg:
> >      maxItems: 1
> >  
> > +  power-domains:
> > +    maxItems: 1
> > +
> >    '#clock-cells':
> >      const: 1
> >  
> > @@ -49,11 +52,25 @@ required:
> >  
> >  additionalProperties: false
> >  
> > +allOf:
> 
> allOf goes just before additionalProperties.
> 

ok, I will fix this.

> > +  - if:
> > +      properties:
> > +        compatible:
> > +          contains:
> > +            enum:
> > +              - mediatek,mt8192-scp_adsp
> 
> For the future: please don't use underscores in compatibles.
> 

Noted!

Thanks,
Allen

> > +    then:
> > +      required:
> > +        - power-domains
> > +
> >  examples:
> >    - |
> > +    #include <dt-bindings/power/mt8192-power.h>
> > +
> >      scp_adsp: clock-controller@10720000 {
> >          compatible = "mediatek,mt8192-scp_adsp";
> >          reg = <0x10720000 0x1000>;
> > +        power-domains = <&spm MT8192_POWER_DOMAIN_ADSP>;
> >          #clock-cells = <1>;
> >      };
> >  
> 
> Best regards,
> Krzysztof
>
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/arm/mediatek/mediatek,mt8192-clock.yaml b/Documentation/devicetree/bindings/arm/mediatek/mediatek,mt8192-clock.yaml
index b57cc2e69efb..cbedef114103 100644
--- a/Documentation/devicetree/bindings/arm/mediatek/mediatek,mt8192-clock.yaml
+++ b/Documentation/devicetree/bindings/arm/mediatek/mediatek,mt8192-clock.yaml
@@ -40,6 +40,9 @@  properties:
   reg:
     maxItems: 1
 
+  power-domains:
+    maxItems: 1
+
   '#clock-cells':
     const: 1
 
@@ -49,11 +52,25 @@  required:
 
 additionalProperties: false
 
+allOf:
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - mediatek,mt8192-scp_adsp
+    then:
+      required:
+        - power-domains
+
 examples:
   - |
+    #include <dt-bindings/power/mt8192-power.h>
+
     scp_adsp: clock-controller@10720000 {
         compatible = "mediatek,mt8192-scp_adsp";
         reg = <0x10720000 0x1000>;
+        power-domains = <&spm MT8192_POWER_DOMAIN_ADSP>;
         #clock-cells = <1>;
     };