diff mbox series

[v4,1/2] dt-bindings: mmc: renesas,sdhi: Fix dtbs-check warning

Message ID 20210817090313.31858-2-biju.das.jz@bp.renesas.com
State Accepted
Commit 4aba5dc71eae041aa1a9240de10ad2e30e9f32dd
Headers show
Series Document RZ/G2L SDHI controller bindings | expand

Commit Message

Biju Das Aug. 17, 2021, 9:03 a.m. UTC
Fix dtbs-check warning pinctrl-names:0:'default' was expected
for r8a77470-iwg23s-sbc.dts file.

Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
Reviewed-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
---
v3->v4:
 * Removed duplicate clock-names for sdhi-r7sxxxx SoC's
 Ref:- https://patchwork.kernel.org/project/linux-renesas-soc/patch/20210804161325.26996-2-biju.das.jz@bp.renesas.com/
v3:
 * New patch to fix the dtbs-check warnings
 Ref:- https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20210804091940.23983-1-biju.das.jz@bp.renesas.com/
---
 .../devicetree/bindings/mmc/renesas,sdhi.yaml | 60 ++++++++++++-------
 1 file changed, 37 insertions(+), 23 deletions(-)

Comments

Rob Herring (Arm) Aug. 18, 2021, 2:12 p.m. UTC | #1
On Tue, 17 Aug 2021 10:03:12 +0100, Biju Das wrote:
> Fix dtbs-check warning pinctrl-names:0:'default' was expected
> for r8a77470-iwg23s-sbc.dts file.
> 
> Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
> Reviewed-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
> ---
> v3->v4:
>  * Removed duplicate clock-names for sdhi-r7sxxxx SoC's
>  Ref:- https://patchwork.kernel.org/project/linux-renesas-soc/patch/20210804161325.26996-2-biju.das.jz@bp.renesas.com/
> v3:
>  * New patch to fix the dtbs-check warnings
>  Ref:- https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20210804091940.23983-1-biju.das.jz@bp.renesas.com/
> ---
>  .../devicetree/bindings/mmc/renesas,sdhi.yaml | 60 ++++++++++++-------
>  1 file changed, 37 insertions(+), 23 deletions(-)
> 

Reviewed-by: Rob Herring <robh@kernel.org>
Ulf Hansson Aug. 24, 2021, 2:56 p.m. UTC | #2
On Tue, 17 Aug 2021 at 11:03, Biju Das <biju.das.jz@bp.renesas.com> wrote:
>

> Fix dtbs-check warning pinctrl-names:0:'default' was expected

> for r8a77470-iwg23s-sbc.dts file.

>

> Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>

> Reviewed-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>


Applied for next, thanks!

Kind regards
Uffe


> ---

> v3->v4:

>  * Removed duplicate clock-names for sdhi-r7sxxxx SoC's

>  Ref:- https://patchwork.kernel.org/project/linux-renesas-soc/patch/20210804161325.26996-2-biju.das.jz@bp.renesas.com/

> v3:

>  * New patch to fix the dtbs-check warnings

>  Ref:- https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20210804091940.23983-1-biju.das.jz@bp.renesas.com/

> ---

>  .../devicetree/bindings/mmc/renesas,sdhi.yaml | 60 ++++++++++++-------

>  1 file changed, 37 insertions(+), 23 deletions(-)

>

> diff --git a/Documentation/devicetree/bindings/mmc/renesas,sdhi.yaml b/Documentation/devicetree/bindings/mmc/renesas,sdhi.yaml

> index 677989bc5924..43584f4f4c7e 100644

> --- a/Documentation/devicetree/bindings/mmc/renesas,sdhi.yaml

> +++ b/Documentation/devicetree/bindings/mmc/renesas,sdhi.yaml

> @@ -9,9 +9,6 @@ title: Renesas SDHI SD/MMC controller

>  maintainers:

>    - Wolfram Sang <wsa+renesas@sang-engineering.com>

>

> -allOf:

> -  - $ref: "mmc-controller.yaml"

> -

>  properties:

>    compatible:

>      oneOf:

> @@ -104,14 +101,46 @@ properties:

>    pinctrl-1:

>      maxItems: 1

>

> -  pinctrl-names:

> -    minItems: 1

> -    items:

> -      - const: default

> -      - const: state_uhs

> +  pinctrl-names: true

>

>    max-frequency: true

>

> +allOf:

> +  - $ref: "mmc-controller.yaml"

> +

> +  - if:

> +      properties:

> +        compatible:

> +          contains:

> +            const: renesas,sdhi-mmc-r8a77470

> +    then:

> +      properties:

> +        pinctrl-names:

> +          items:

> +            - const: state_uhs

> +    else:

> +      properties:

> +        pinctrl-names:

> +          minItems: 1

> +          items:

> +            - const: default

> +            - const: state_uhs

> +

> +  - if:

> +      properties:

> +        compatible:

> +          contains:

> +            enum:

> +              - renesas,sdhi-r7s72100

> +              - renesas,sdhi-r7s9210

> +    then:

> +      required:

> +        - clock-names

> +      description:

> +        The internal card detection logic that exists in these controllers is

> +        sectioned off to be run by a separate second clock source to allow

> +        the main core clock to be turned off to save power.

> +

>  required:

>    - compatible

>    - reg

> @@ -119,21 +148,6 @@ required:

>    - clocks

>    - power-domains

>

> -if:

> -  properties:

> -    compatible:

> -      contains:

> -        enum:

> -          - renesas,sdhi-r7s72100

> -          - renesas,sdhi-r7s9210

> -then:

> -  required:

> -    - clock-names

> -  description:

> -    The internal card detection logic that exists in these controllers is

> -    sectioned off to be run by a separate second clock source to allow

> -    the main core clock to be turned off to save power.

> -

>  unevaluatedProperties: false

>

>  examples:

> --

> 2.17.1

>
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/mmc/renesas,sdhi.yaml b/Documentation/devicetree/bindings/mmc/renesas,sdhi.yaml
index 677989bc5924..43584f4f4c7e 100644
--- a/Documentation/devicetree/bindings/mmc/renesas,sdhi.yaml
+++ b/Documentation/devicetree/bindings/mmc/renesas,sdhi.yaml
@@ -9,9 +9,6 @@  title: Renesas SDHI SD/MMC controller
 maintainers:
   - Wolfram Sang <wsa+renesas@sang-engineering.com>
 
-allOf:
-  - $ref: "mmc-controller.yaml"
-
 properties:
   compatible:
     oneOf:
@@ -104,14 +101,46 @@  properties:
   pinctrl-1:
     maxItems: 1
 
-  pinctrl-names:
-    minItems: 1
-    items:
-      - const: default
-      - const: state_uhs
+  pinctrl-names: true
 
   max-frequency: true
 
+allOf:
+  - $ref: "mmc-controller.yaml"
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            const: renesas,sdhi-mmc-r8a77470
+    then:
+      properties:
+        pinctrl-names:
+          items:
+            - const: state_uhs
+    else:
+      properties:
+        pinctrl-names:
+          minItems: 1
+          items:
+            - const: default
+            - const: state_uhs
+
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - renesas,sdhi-r7s72100
+              - renesas,sdhi-r7s9210
+    then:
+      required:
+        - clock-names
+      description:
+        The internal card detection logic that exists in these controllers is
+        sectioned off to be run by a separate second clock source to allow
+        the main core clock to be turned off to save power.
+
 required:
   - compatible
   - reg
@@ -119,21 +148,6 @@  required:
   - clocks
   - power-domains
 
-if:
-  properties:
-    compatible:
-      contains:
-        enum:
-          - renesas,sdhi-r7s72100
-          - renesas,sdhi-r7s9210
-then:
-  required:
-    - clock-names
-  description:
-    The internal card detection logic that exists in these controllers is
-    sectioned off to be run by a separate second clock source to allow
-    the main core clock to be turned off to save power.
-
 unevaluatedProperties: false
 
 examples: