diff mbox series

arm64: dts: renesas: r8a7796: sort nodes

Message ID 1566219378-23126-1-git-send-email-ykaneko0929@gmail.com (mailing list archive)
State Mainlined
Commit 13a398a17afed664d3539d9d2c85fcb489b494e5
Headers show
Series arm64: dts: renesas: r8a7796: sort nodes | expand

Commit Message

Yoshihiro Kaneko Aug. 19, 2019, 12:56 p.m. UTC
Sort nodes.

If node address is present
   * Sort by node address, grouping all nodes with the same compat string
     and sorting the group alphabetically.
Else
   * Sort alphabetically

This should not have any run-time effect.

Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com>
---

This patch is based on the master branch of Geert Uytterhoeven's renesas-devel
tree.

 arch/arm64/boot/dts/renesas/r8a7796.dtsi | 152 +++++++++++++++----------------
 1 file changed, 76 insertions(+), 76 deletions(-)

Comments

Simon Horman Aug. 21, 2019, 8:57 a.m. UTC | #1
On Mon, Aug 19, 2019 at 09:56:18PM +0900, Yoshihiro Kaneko wrote:
> Sort nodes.
> 
> If node address is present
>    * Sort by node address, grouping all nodes with the same compat string
>      and sorting the group alphabetically.
> Else
>    * Sort alphabetically
> 
> This should not have any run-time effect.
> 
> Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com>

Sorry, I feel that I have missed this in other review's too,
but, isn't canfd out of order. Its bus address seems to place it
before dmac0. Or do we prefer to keep it grouped with the can nodes?

The above notwithstanding,

Reviewed-by: Simon Horman <horms+renesas@verge.net.au>

> ---
> 
> This patch is based on the master branch of Geert Uytterhoeven's renesas-devel
> tree.
> 
>  arch/arm64/boot/dts/renesas/r8a7796.dtsi | 152 +++++++++++++++----------------
>  1 file changed, 76 insertions(+), 76 deletions(-)
> 
> diff --git a/arch/arm64/boot/dts/renesas/r8a7796.dtsi b/arch/arm64/boot/dts/renesas/r8a7796.dtsi
> index 26df5b8..3dc9d73 100644
> --- a/arch/arm64/boot/dts/renesas/r8a7796.dtsi
> +++ b/arch/arm64/boot/dts/renesas/r8a7796.dtsi
> @@ -1833,6 +1833,17 @@
>  				      "ssi.1", "ssi.0";
>  			status = "disabled";
>  
> +			rcar_sound,ctu {
> +				ctu00: ctu-0 { };
> +				ctu01: ctu-1 { };
> +				ctu02: ctu-2 { };
> +				ctu03: ctu-3 { };
> +				ctu10: ctu-4 { };
> +				ctu11: ctu-5 { };
> +				ctu12: ctu-6 { };
> +				ctu13: ctu-7 { };
> +			};
> +
>  			rcar_sound,dvc {
>  				dvc0: dvc-0 {
>  					dmas = <&audma1 0xbc>;
> @@ -1849,17 +1860,6 @@
>  				mix1: mix-1 { };
>  			};
>  
> -			rcar_sound,ctu {
> -				ctu00: ctu-0 { };
> -				ctu01: ctu-1 { };
> -				ctu02: ctu-2 { };
> -				ctu03: ctu-3 { };
> -				ctu10: ctu-4 { };
> -				ctu11: ctu-5 { };
> -				ctu12: ctu-6 { };
> -				ctu13: ctu-7 { };
> -			};
> -
>  			rcar_sound,src {
>  				src0: src-0 {
>  					interrupts = <GIC_SPI 352 IRQ_TYPE_LEVEL_HIGH>;
> @@ -1913,6 +1913,59 @@
>  				};
>  			};
>  
> +			rcar_sound,ssi {
> +				ssi0: ssi-0 {
> +					interrupts = <GIC_SPI 370 IRQ_TYPE_LEVEL_HIGH>;
> +					dmas = <&audma0 0x01>, <&audma1 0x02>;
> +					dma-names = "rx", "tx";
> +				};
> +				ssi1: ssi-1 {
> +					interrupts = <GIC_SPI 371 IRQ_TYPE_LEVEL_HIGH>;
> +					dmas = <&audma0 0x03>, <&audma1 0x04>;
> +					dma-names = "rx", "tx";
> +				};
> +				ssi2: ssi-2 {
> +					interrupts = <GIC_SPI 372 IRQ_TYPE_LEVEL_HIGH>;
> +					dmas = <&audma0 0x05>, <&audma1 0x06>;
> +					dma-names = "rx", "tx";
> +				};
> +				ssi3: ssi-3 {
> +					interrupts = <GIC_SPI 373 IRQ_TYPE_LEVEL_HIGH>;
> +					dmas = <&audma0 0x07>, <&audma1 0x08>;
> +					dma-names = "rx", "tx";
> +				};
> +				ssi4: ssi-4 {
> +					interrupts = <GIC_SPI 374 IRQ_TYPE_LEVEL_HIGH>;
> +					dmas = <&audma0 0x09>, <&audma1 0x0a>;
> +					dma-names = "rx", "tx";
> +				};
> +				ssi5: ssi-5 {
> +					interrupts = <GIC_SPI 375 IRQ_TYPE_LEVEL_HIGH>;
> +					dmas = <&audma0 0x0b>, <&audma1 0x0c>;
> +					dma-names = "rx", "tx";
> +				};
> +				ssi6: ssi-6 {
> +					interrupts = <GIC_SPI 376 IRQ_TYPE_LEVEL_HIGH>;
> +					dmas = <&audma0 0x0d>, <&audma1 0x0e>;
> +					dma-names = "rx", "tx";
> +				};
> +				ssi7: ssi-7 {
> +					interrupts = <GIC_SPI 377 IRQ_TYPE_LEVEL_HIGH>;
> +					dmas = <&audma0 0x0f>, <&audma1 0x10>;
> +					dma-names = "rx", "tx";
> +				};
> +				ssi8: ssi-8 {
> +					interrupts = <GIC_SPI 378 IRQ_TYPE_LEVEL_HIGH>;
> +					dmas = <&audma0 0x11>, <&audma1 0x12>;
> +					dma-names = "rx", "tx";
> +				};
> +				ssi9: ssi-9 {
> +					interrupts = <GIC_SPI 379 IRQ_TYPE_LEVEL_HIGH>;
> +					dmas = <&audma0 0x13>, <&audma1 0x14>;
> +					dma-names = "rx", "tx";
> +				};
> +			};
> +
>  			rcar_sound,ssiu {
>  				ssiu00: ssiu-0 {
>  					dmas = <&audma0 0x15>, <&audma1 0x16>;
> @@ -2123,59 +2176,6 @@
>  					dma-names = "rx", "tx";
>  				};
>  			};
> -
> -			rcar_sound,ssi {
> -				ssi0: ssi-0 {
> -					interrupts = <GIC_SPI 370 IRQ_TYPE_LEVEL_HIGH>;
> -					dmas = <&audma0 0x01>, <&audma1 0x02>;
> -					dma-names = "rx", "tx";
> -				};
> -				ssi1: ssi-1 {
> -					interrupts = <GIC_SPI 371 IRQ_TYPE_LEVEL_HIGH>;
> -					dmas = <&audma0 0x03>, <&audma1 0x04>;
> -					dma-names = "rx", "tx";
> -				};
> -				ssi2: ssi-2 {
> -					interrupts = <GIC_SPI 372 IRQ_TYPE_LEVEL_HIGH>;
> -					dmas = <&audma0 0x05>, <&audma1 0x06>;
> -					dma-names = "rx", "tx";
> -				};
> -				ssi3: ssi-3 {
> -					interrupts = <GIC_SPI 373 IRQ_TYPE_LEVEL_HIGH>;
> -					dmas = <&audma0 0x07>, <&audma1 0x08>;
> -					dma-names = "rx", "tx";
> -				};
> -				ssi4: ssi-4 {
> -					interrupts = <GIC_SPI 374 IRQ_TYPE_LEVEL_HIGH>;
> -					dmas = <&audma0 0x09>, <&audma1 0x0a>;
> -					dma-names = "rx", "tx";
> -				};
> -				ssi5: ssi-5 {
> -					interrupts = <GIC_SPI 375 IRQ_TYPE_LEVEL_HIGH>;
> -					dmas = <&audma0 0x0b>, <&audma1 0x0c>;
> -					dma-names = "rx", "tx";
> -				};
> -				ssi6: ssi-6 {
> -					interrupts = <GIC_SPI 376 IRQ_TYPE_LEVEL_HIGH>;
> -					dmas = <&audma0 0x0d>, <&audma1 0x0e>;
> -					dma-names = "rx", "tx";
> -				};
> -				ssi7: ssi-7 {
> -					interrupts = <GIC_SPI 377 IRQ_TYPE_LEVEL_HIGH>;
> -					dmas = <&audma0 0x0f>, <&audma1 0x10>;
> -					dma-names = "rx", "tx";
> -				};
> -				ssi8: ssi-8 {
> -					interrupts = <GIC_SPI 378 IRQ_TYPE_LEVEL_HIGH>;
> -					dmas = <&audma0 0x11>, <&audma1 0x12>;
> -					dma-names = "rx", "tx";
> -				};
> -				ssi9: ssi-9 {
> -					interrupts = <GIC_SPI 379 IRQ_TYPE_LEVEL_HIGH>;
> -					dmas = <&audma0 0x13>, <&audma1 0x14>;
> -					dma-names = "rx", "tx";
> -				};
> -			};
>  		};
>  
>  		audma0: dma-controller@ec700000 {
> @@ -2860,6 +2860,18 @@
>  			thermal-sensors = <&tsc 2>;
>  			sustainable-power = <3874>;
>  
> +			cooling-maps {
> +				map0 {
> +					trip = <&target>;
> +					cooling-device = <&a57_0 2 4>;
> +					contribution = <1024>;
> +				};
> +				map1 {
> +					trip = <&target>;
> +					cooling-device = <&a53_0 0 2>;
> +					contribution = <1024>;
> +				};
> +			};
>  			trips {
>  				target: trip-point1 {
>  					temperature = <100000>;
> @@ -2873,18 +2885,6 @@
>  					type = "critical";
>  				};
>  			};
> -			cooling-maps {
> -				map0 {
> -					trip = <&target>;
> -					cooling-device = <&a57_0 2 4>;
> -					contribution = <1024>;
> -				};
> -				map1 {
> -					trip = <&target>;
> -					cooling-device = <&a53_0 0 2>;
> -					contribution = <1024>;
> -				};
> -			};
>  		};
>  	};
>  
> -- 
> 1.9.1
>
Geert Uytterhoeven Aug. 21, 2019, 9:02 a.m. UTC | #2
On Wed, Aug 21, 2019 at 10:57 AM Simon Horman <horms@verge.net.au> wrote:
> On Mon, Aug 19, 2019 at 09:56:18PM +0900, Yoshihiro Kaneko wrote:
> > Sort nodes.
> >
> > If node address is present
> >    * Sort by node address, grouping all nodes with the same compat string
> >      and sorting the group alphabetically.
> > Else
> >    * Sort alphabetically
> >
> > This should not have any run-time effect.
> >
> > Signed-off-by: Yoshihiro Kaneko <ykaneko0929@gmail.com>

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
i.e. will queue in renesas-devel for v5.4.

> Sorry, I feel that I have missed this in other review's too,
> but, isn't canfd out of order. Its bus address seems to place it
> before dmac0. Or do we prefer to keep it grouped with the can nodes?

We always group it with the can nodes.

BTW, i2c_dvfs is similar, but it seems we deviated from that in at least one
case.

Once the nodes are sorted, we can run my soc-dts-diff script and fix the
last small deviations, crickets, and typos.

> The above notwithstanding,
>
> Reviewed-by: Simon Horman <horms+renesas@verge.net.au>

Thanks!

Gr{oetje,eeting}s,

                        Geert
diff mbox series

Patch

diff --git a/arch/arm64/boot/dts/renesas/r8a7796.dtsi b/arch/arm64/boot/dts/renesas/r8a7796.dtsi
index 26df5b8..3dc9d73 100644
--- a/arch/arm64/boot/dts/renesas/r8a7796.dtsi
+++ b/arch/arm64/boot/dts/renesas/r8a7796.dtsi
@@ -1833,6 +1833,17 @@ 
 				      "ssi.1", "ssi.0";
 			status = "disabled";
 
+			rcar_sound,ctu {
+				ctu00: ctu-0 { };
+				ctu01: ctu-1 { };
+				ctu02: ctu-2 { };
+				ctu03: ctu-3 { };
+				ctu10: ctu-4 { };
+				ctu11: ctu-5 { };
+				ctu12: ctu-6 { };
+				ctu13: ctu-7 { };
+			};
+
 			rcar_sound,dvc {
 				dvc0: dvc-0 {
 					dmas = <&audma1 0xbc>;
@@ -1849,17 +1860,6 @@ 
 				mix1: mix-1 { };
 			};
 
-			rcar_sound,ctu {
-				ctu00: ctu-0 { };
-				ctu01: ctu-1 { };
-				ctu02: ctu-2 { };
-				ctu03: ctu-3 { };
-				ctu10: ctu-4 { };
-				ctu11: ctu-5 { };
-				ctu12: ctu-6 { };
-				ctu13: ctu-7 { };
-			};
-
 			rcar_sound,src {
 				src0: src-0 {
 					interrupts = <GIC_SPI 352 IRQ_TYPE_LEVEL_HIGH>;
@@ -1913,6 +1913,59 @@ 
 				};
 			};
 
+			rcar_sound,ssi {
+				ssi0: ssi-0 {
+					interrupts = <GIC_SPI 370 IRQ_TYPE_LEVEL_HIGH>;
+					dmas = <&audma0 0x01>, <&audma1 0x02>;
+					dma-names = "rx", "tx";
+				};
+				ssi1: ssi-1 {
+					interrupts = <GIC_SPI 371 IRQ_TYPE_LEVEL_HIGH>;
+					dmas = <&audma0 0x03>, <&audma1 0x04>;
+					dma-names = "rx", "tx";
+				};
+				ssi2: ssi-2 {
+					interrupts = <GIC_SPI 372 IRQ_TYPE_LEVEL_HIGH>;
+					dmas = <&audma0 0x05>, <&audma1 0x06>;
+					dma-names = "rx", "tx";
+				};
+				ssi3: ssi-3 {
+					interrupts = <GIC_SPI 373 IRQ_TYPE_LEVEL_HIGH>;
+					dmas = <&audma0 0x07>, <&audma1 0x08>;
+					dma-names = "rx", "tx";
+				};
+				ssi4: ssi-4 {
+					interrupts = <GIC_SPI 374 IRQ_TYPE_LEVEL_HIGH>;
+					dmas = <&audma0 0x09>, <&audma1 0x0a>;
+					dma-names = "rx", "tx";
+				};
+				ssi5: ssi-5 {
+					interrupts = <GIC_SPI 375 IRQ_TYPE_LEVEL_HIGH>;
+					dmas = <&audma0 0x0b>, <&audma1 0x0c>;
+					dma-names = "rx", "tx";
+				};
+				ssi6: ssi-6 {
+					interrupts = <GIC_SPI 376 IRQ_TYPE_LEVEL_HIGH>;
+					dmas = <&audma0 0x0d>, <&audma1 0x0e>;
+					dma-names = "rx", "tx";
+				};
+				ssi7: ssi-7 {
+					interrupts = <GIC_SPI 377 IRQ_TYPE_LEVEL_HIGH>;
+					dmas = <&audma0 0x0f>, <&audma1 0x10>;
+					dma-names = "rx", "tx";
+				};
+				ssi8: ssi-8 {
+					interrupts = <GIC_SPI 378 IRQ_TYPE_LEVEL_HIGH>;
+					dmas = <&audma0 0x11>, <&audma1 0x12>;
+					dma-names = "rx", "tx";
+				};
+				ssi9: ssi-9 {
+					interrupts = <GIC_SPI 379 IRQ_TYPE_LEVEL_HIGH>;
+					dmas = <&audma0 0x13>, <&audma1 0x14>;
+					dma-names = "rx", "tx";
+				};
+			};
+
 			rcar_sound,ssiu {
 				ssiu00: ssiu-0 {
 					dmas = <&audma0 0x15>, <&audma1 0x16>;
@@ -2123,59 +2176,6 @@ 
 					dma-names = "rx", "tx";
 				};
 			};
-
-			rcar_sound,ssi {
-				ssi0: ssi-0 {
-					interrupts = <GIC_SPI 370 IRQ_TYPE_LEVEL_HIGH>;
-					dmas = <&audma0 0x01>, <&audma1 0x02>;
-					dma-names = "rx", "tx";
-				};
-				ssi1: ssi-1 {
-					interrupts = <GIC_SPI 371 IRQ_TYPE_LEVEL_HIGH>;
-					dmas = <&audma0 0x03>, <&audma1 0x04>;
-					dma-names = "rx", "tx";
-				};
-				ssi2: ssi-2 {
-					interrupts = <GIC_SPI 372 IRQ_TYPE_LEVEL_HIGH>;
-					dmas = <&audma0 0x05>, <&audma1 0x06>;
-					dma-names = "rx", "tx";
-				};
-				ssi3: ssi-3 {
-					interrupts = <GIC_SPI 373 IRQ_TYPE_LEVEL_HIGH>;
-					dmas = <&audma0 0x07>, <&audma1 0x08>;
-					dma-names = "rx", "tx";
-				};
-				ssi4: ssi-4 {
-					interrupts = <GIC_SPI 374 IRQ_TYPE_LEVEL_HIGH>;
-					dmas = <&audma0 0x09>, <&audma1 0x0a>;
-					dma-names = "rx", "tx";
-				};
-				ssi5: ssi-5 {
-					interrupts = <GIC_SPI 375 IRQ_TYPE_LEVEL_HIGH>;
-					dmas = <&audma0 0x0b>, <&audma1 0x0c>;
-					dma-names = "rx", "tx";
-				};
-				ssi6: ssi-6 {
-					interrupts = <GIC_SPI 376 IRQ_TYPE_LEVEL_HIGH>;
-					dmas = <&audma0 0x0d>, <&audma1 0x0e>;
-					dma-names = "rx", "tx";
-				};
-				ssi7: ssi-7 {
-					interrupts = <GIC_SPI 377 IRQ_TYPE_LEVEL_HIGH>;
-					dmas = <&audma0 0x0f>, <&audma1 0x10>;
-					dma-names = "rx", "tx";
-				};
-				ssi8: ssi-8 {
-					interrupts = <GIC_SPI 378 IRQ_TYPE_LEVEL_HIGH>;
-					dmas = <&audma0 0x11>, <&audma1 0x12>;
-					dma-names = "rx", "tx";
-				};
-				ssi9: ssi-9 {
-					interrupts = <GIC_SPI 379 IRQ_TYPE_LEVEL_HIGH>;
-					dmas = <&audma0 0x13>, <&audma1 0x14>;
-					dma-names = "rx", "tx";
-				};
-			};
 		};
 
 		audma0: dma-controller@ec700000 {
@@ -2860,6 +2860,18 @@ 
 			thermal-sensors = <&tsc 2>;
 			sustainable-power = <3874>;
 
+			cooling-maps {
+				map0 {
+					trip = <&target>;
+					cooling-device = <&a57_0 2 4>;
+					contribution = <1024>;
+				};
+				map1 {
+					trip = <&target>;
+					cooling-device = <&a53_0 0 2>;
+					contribution = <1024>;
+				};
+			};
 			trips {
 				target: trip-point1 {
 					temperature = <100000>;
@@ -2873,18 +2885,6 @@ 
 					type = "critical";
 				};
 			};
-			cooling-maps {
-				map0 {
-					trip = <&target>;
-					cooling-device = <&a57_0 2 4>;
-					contribution = <1024>;
-				};
-				map1 {
-					trip = <&target>;
-					cooling-device = <&a53_0 0 2>;
-					contribution = <1024>;
-				};
-			};
 		};
 	};