[v4,1/9] dt-bindings: arm: mediatek: Sort entries by SoC then board compatibles

Message ID 20231213150435.4134390-2-wenst@chromium.org
State New
Headers
Series arm64: dts: mediatek: Add MT8186 Corsola Chromebooks |

Commit Message

Chen-Yu Tsai Dec. 13, 2023, 3:04 p.m. UTC
  Some of the new MediaTek board entries were inserted in a chronological
order, or just randomly. This makes it harder to search for an entry.

Sort the entries by first grouping by SoC, then sorting by board
compatible strings. Also add a comment at the top asking people to do
the same.

Signed-off-by: Chen-Yu Tsai <wenst@chromium.org>
Acked-by: Conor Dooley <conor.dooley@microchip.com>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
---
Changes since v3:
- Collected reviewed-by from Angelo
Changes since v2:
- none
Changes since v1:
- Collected ack from Conor
---
 .../devicetree/bindings/arm/mediatek.yaml     | 123 +++++++++---------
 1 file changed, 62 insertions(+), 61 deletions(-)
  

Comments

Matthias Brugger Jan. 22, 2024, 8:02 a.m. UTC | #1
On 13/12/2023 16:04, Chen-Yu Tsai wrote:
> Some of the new MediaTek board entries were inserted in a chronological
> order, or just randomly. This makes it harder to search for an entry.
> 
> Sort the entries by first grouping by SoC, then sorting by board
> compatible strings. Also add a comment at the top asking people to do
> the same.
> 
> Signed-off-by: Chen-Yu Tsai <wenst@chromium.org>
> Acked-by: Conor Dooley <conor.dooley@microchip.com>
> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>

Does not apply cleanly, would you mind to rebase the whole series onto v6.8-rc1.

Regards,
Matthias

> ---
> Changes since v3:
> - Collected reviewed-by from Angelo
> Changes since v2:
> - none
> Changes since v1:
> - Collected ack from Conor
> ---
>   .../devicetree/bindings/arm/mediatek.yaml     | 123 +++++++++---------
>   1 file changed, 62 insertions(+), 61 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/arm/mediatek.yaml b/Documentation/devicetree/bindings/arm/mediatek.yaml
> index a5999b3afc35..60337b439744 100644
> --- a/Documentation/devicetree/bindings/arm/mediatek.yaml
> +++ b/Documentation/devicetree/bindings/arm/mediatek.yaml
> @@ -17,6 +17,7 @@ properties:
>       const: '/'
>     compatible:
>       oneOf:
> +      # Sort by SoC (last) compatible, then board compatible
>         - items:
>             - enum:
>                 - mediatek,mt2701-evb
> @@ -129,71 +130,10 @@ properties:
>             - enum:
>                 - mediatek,mt8173-evb
>             - const: mediatek,mt8173
> -      - items:
> -          - enum:
> -              - mediatek,mt8183-evb
> -          - const: mediatek,mt8183
> -      - description: Google Hayato rev5
> -        items:
> -          - const: google,hayato-rev5-sku2
> -          - const: google,hayato-sku2
> -          - const: google,hayato
> -          - const: mediatek,mt8192
> -      - description: Google Hayato
> -        items:
> -          - const: google,hayato-rev1
> -          - const: google,hayato
> -          - const: mediatek,mt8192
> -      - description: Google Spherion rev4 (Acer Chromebook 514)
> -        items:
> -          - const: google,spherion-rev4
> -          - const: google,spherion
> -          - const: mediatek,mt8192
> -      - description: Google Spherion (Acer Chromebook 514)
> -        items:
> -          - const: google,spherion-rev3
> -          - const: google,spherion-rev2
> -          - const: google,spherion-rev1
> -          - const: google,spherion-rev0
> -          - const: google,spherion
> -          - const: mediatek,mt8192
> -      - description: Acer Tomato (Acer Chromebook Spin 513 CP513-2H)
> -        items:
> -          - enum:
> -              - google,tomato-rev2
> -              - google,tomato-rev1
> -          - const: google,tomato
> -          - const: mediatek,mt8195
> -      - description: Acer Tomato rev3 - 4 (Acer Chromebook Spin 513 CP513-2H)
> -        items:
> -          - const: google,tomato-rev4
> -          - const: google,tomato-rev3
> -          - const: google,tomato
> -          - const: mediatek,mt8195
> -      - items:
> -          - enum:
> -              - mediatek,mt8186-evb
> -          - const: mediatek,mt8186
> -      - items:
> -          - enum:
> -              - mediatek,mt8192-evb
> -          - const: mediatek,mt8192
> -      - items:
> -          - enum:
> -              - mediatek,mt8195-demo
> -              - mediatek,mt8195-evb
> -          - const: mediatek,mt8195
>         - description: Google Burnet (HP Chromebook x360 11MK G3 EE)
>           items:
>             - const: google,burnet
>             - const: mediatek,mt8183
> -      - description: Google Krane (Lenovo IdeaPad Duet, 10e,...)
> -        items:
> -          - enum:
> -              - google,krane-sku0
> -              - google,krane-sku176
> -          - const: google,krane
> -          - const: mediatek,mt8183
>         - description: Google Cozmo (Acer Chromebook 314)
>           items:
>             - const: google,cozmo
> @@ -244,6 +184,13 @@ properties:
>                 - google,kodama-sku32
>             - const: google,kodama
>             - const: mediatek,mt8183
> +      - description: Google Krane (Lenovo IdeaPad Duet, 10e,...)
> +        items:
> +          - enum:
> +              - google,krane-sku0
> +              - google,krane-sku176
> +          - const: google,krane
> +          - const: mediatek,mt8183
>         - description: Google Willow (Acer Chromebook 311 C722/C722T)
>           items:
>             - enum:
> @@ -251,10 +198,64 @@ properties:
>                 - google,willow-sku1
>             - const: google,willow
>             - const: mediatek,mt8183
> +      - items:
> +          - enum:
> +              - mediatek,mt8183-evb
> +          - const: mediatek,mt8183
>         - items:
>             - enum:
>                 - mediatek,mt8183-pumpkin
>             - const: mediatek,mt8183
> +      - items:
> +          - enum:
> +              - mediatek,mt8186-evb
> +          - const: mediatek,mt8186
> +      - description: Google Hayato
> +        items:
> +          - const: google,hayato-rev1
> +          - const: google,hayato
> +          - const: mediatek,mt8192
> +      - description: Google Hayato rev5
> +        items:
> +          - const: google,hayato-rev5-sku2
> +          - const: google,hayato-sku2
> +          - const: google,hayato
> +          - const: mediatek,mt8192
> +      - description: Google Spherion (Acer Chromebook 514)
> +        items:
> +          - const: google,spherion-rev3
> +          - const: google,spherion-rev2
> +          - const: google,spherion-rev1
> +          - const: google,spherion-rev0
> +          - const: google,spherion
> +          - const: mediatek,mt8192
> +      - description: Google Spherion rev4 (Acer Chromebook 514)
> +        items:
> +          - const: google,spherion-rev4
> +          - const: google,spherion
> +          - const: mediatek,mt8192
> +      - items:
> +          - enum:
> +              - mediatek,mt8192-evb
> +          - const: mediatek,mt8192
> +      - description: Acer Tomato (Acer Chromebook Spin 513 CP513-2H)
> +        items:
> +          - enum:
> +              - google,tomato-rev2
> +              - google,tomato-rev1
> +          - const: google,tomato
> +          - const: mediatek,mt8195
> +      - description: Acer Tomato rev3 - 4 (Acer Chromebook Spin 513 CP513-2H)
> +        items:
> +          - const: google,tomato-rev4
> +          - const: google,tomato-rev3
> +          - const: google,tomato
> +          - const: mediatek,mt8195
> +      - items:
> +          - enum:
> +              - mediatek,mt8195-demo
> +              - mediatek,mt8195-evb
> +          - const: mediatek,mt8195
>         - items:
>             - enum:
>                 - mediatek,mt8365-evk
  
Chen-Yu Tsai Jan. 22, 2024, 8:17 a.m. UTC | #2
On Mon, Jan 22, 2024 at 4:02 PM Matthias Brugger <matthias.bgg@gmail.com> wrote:
> On 13/12/2023 16:04, Chen-Yu Tsai wrote:
> > Some of the new MediaTek board entries were inserted in a chronological
> > order, or just randomly. This makes it harder to search for an entry.
> >
> > Sort the entries by first grouping by SoC, then sorting by board
> > compatible strings. Also add a comment at the top asking people to do
> > the same.
> >
> > Signed-off-by: Chen-Yu Tsai <wenst@chromium.org>
> > Acked-by: Conor Dooley <conor.dooley@microchip.com>
> > Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
>
> Does not apply cleanly, would you mind to rebase the whole series onto v68-rc1.

Sure. There's still a bit of discussion on patch 6. After that is resolved
I'll send a v5 which will also address some review comments.

ChenYu
  

Patch

diff --git a/Documentation/devicetree/bindings/arm/mediatek.yaml b/Documentation/devicetree/bindings/arm/mediatek.yaml
index a5999b3afc35..60337b439744 100644
--- a/Documentation/devicetree/bindings/arm/mediatek.yaml
+++ b/Documentation/devicetree/bindings/arm/mediatek.yaml
@@ -17,6 +17,7 @@  properties:
     const: '/'
   compatible:
     oneOf:
+      # Sort by SoC (last) compatible, then board compatible
       - items:
           - enum:
               - mediatek,mt2701-evb
@@ -129,71 +130,10 @@  properties:
           - enum:
               - mediatek,mt8173-evb
           - const: mediatek,mt8173
-      - items:
-          - enum:
-              - mediatek,mt8183-evb
-          - const: mediatek,mt8183
-      - description: Google Hayato rev5
-        items:
-          - const: google,hayato-rev5-sku2
-          - const: google,hayato-sku2
-          - const: google,hayato
-          - const: mediatek,mt8192
-      - description: Google Hayato
-        items:
-          - const: google,hayato-rev1
-          - const: google,hayato
-          - const: mediatek,mt8192
-      - description: Google Spherion rev4 (Acer Chromebook 514)
-        items:
-          - const: google,spherion-rev4
-          - const: google,spherion
-          - const: mediatek,mt8192
-      - description: Google Spherion (Acer Chromebook 514)
-        items:
-          - const: google,spherion-rev3
-          - const: google,spherion-rev2
-          - const: google,spherion-rev1
-          - const: google,spherion-rev0
-          - const: google,spherion
-          - const: mediatek,mt8192
-      - description: Acer Tomato (Acer Chromebook Spin 513 CP513-2H)
-        items:
-          - enum:
-              - google,tomato-rev2
-              - google,tomato-rev1
-          - const: google,tomato
-          - const: mediatek,mt8195
-      - description: Acer Tomato rev3 - 4 (Acer Chromebook Spin 513 CP513-2H)
-        items:
-          - const: google,tomato-rev4
-          - const: google,tomato-rev3
-          - const: google,tomato
-          - const: mediatek,mt8195
-      - items:
-          - enum:
-              - mediatek,mt8186-evb
-          - const: mediatek,mt8186
-      - items:
-          - enum:
-              - mediatek,mt8192-evb
-          - const: mediatek,mt8192
-      - items:
-          - enum:
-              - mediatek,mt8195-demo
-              - mediatek,mt8195-evb
-          - const: mediatek,mt8195
       - description: Google Burnet (HP Chromebook x360 11MK G3 EE)
         items:
           - const: google,burnet
           - const: mediatek,mt8183
-      - description: Google Krane (Lenovo IdeaPad Duet, 10e,...)
-        items:
-          - enum:
-              - google,krane-sku0
-              - google,krane-sku176
-          - const: google,krane
-          - const: mediatek,mt8183
       - description: Google Cozmo (Acer Chromebook 314)
         items:
           - const: google,cozmo
@@ -244,6 +184,13 @@  properties:
               - google,kodama-sku32
           - const: google,kodama
           - const: mediatek,mt8183
+      - description: Google Krane (Lenovo IdeaPad Duet, 10e,...)
+        items:
+          - enum:
+              - google,krane-sku0
+              - google,krane-sku176
+          - const: google,krane
+          - const: mediatek,mt8183
       - description: Google Willow (Acer Chromebook 311 C722/C722T)
         items:
           - enum:
@@ -251,10 +198,64 @@  properties:
               - google,willow-sku1
           - const: google,willow
           - const: mediatek,mt8183
+      - items:
+          - enum:
+              - mediatek,mt8183-evb
+          - const: mediatek,mt8183
       - items:
           - enum:
               - mediatek,mt8183-pumpkin
           - const: mediatek,mt8183
+      - items:
+          - enum:
+              - mediatek,mt8186-evb
+          - const: mediatek,mt8186
+      - description: Google Hayato
+        items:
+          - const: google,hayato-rev1
+          - const: google,hayato
+          - const: mediatek,mt8192
+      - description: Google Hayato rev5
+        items:
+          - const: google,hayato-rev5-sku2
+          - const: google,hayato-sku2
+          - const: google,hayato
+          - const: mediatek,mt8192
+      - description: Google Spherion (Acer Chromebook 514)
+        items:
+          - const: google,spherion-rev3
+          - const: google,spherion-rev2
+          - const: google,spherion-rev1
+          - const: google,spherion-rev0
+          - const: google,spherion
+          - const: mediatek,mt8192
+      - description: Google Spherion rev4 (Acer Chromebook 514)
+        items:
+          - const: google,spherion-rev4
+          - const: google,spherion
+          - const: mediatek,mt8192
+      - items:
+          - enum:
+              - mediatek,mt8192-evb
+          - const: mediatek,mt8192
+      - description: Acer Tomato (Acer Chromebook Spin 513 CP513-2H)
+        items:
+          - enum:
+              - google,tomato-rev2
+              - google,tomato-rev1
+          - const: google,tomato
+          - const: mediatek,mt8195
+      - description: Acer Tomato rev3 - 4 (Acer Chromebook Spin 513 CP513-2H)
+        items:
+          - const: google,tomato-rev4
+          - const: google,tomato-rev3
+          - const: google,tomato
+          - const: mediatek,mt8195
+      - items:
+          - enum:
+              - mediatek,mt8195-demo
+              - mediatek,mt8195-evb
+          - const: mediatek,mt8195
       - items:
           - enum:
               - mediatek,mt8365-evk