diff mbox

[v4,1/8] arm64: dts: rockchip: Clean up /memory nodes

Message ID 1458136727-32075-2-git-send-email-afaerber@suse.de (mailing list archive)
State New, archived
Headers show

Commit Message

Andreas Färber March 16, 2016, 1:58 p.m. UTC
A dtc update results in warnings for nodes with reg property but without
unit address in the node name, so rename /memory to /memory@0.

Signed-off-by: Andreas Färber <afaerber@suse.de>
---
 v4: New - complements GeekBox patch 4/8
 
 arch/arm64/boot/dts/rockchip/rk3368-evb.dtsi | 2 +-
 arch/arm64/boot/dts/rockchip/rk3368-r88.dts  | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

Comments

Heiko Stübner March 19, 2016, 8:04 a.m. UTC | #1
Am Mittwoch, 16. März 2016, 14:58:39 schrieb Andreas Färber:
> A dtc update results in warnings for nodes with reg property but without
> unit address in the node name, so rename /memory to /memory@0.
> 
> Signed-off-by: Andreas Färber <afaerber@suse.de>

applied to a dts64-fixes branch for 4.6, after changing the commit message to
----
A dtc update results in warnings for nodes with reg property but without
unit address in the node name, so rename /memory to /memory@startaddress
(memory starts at 0 in the case of the rk3368).
----

To clarify that the @0 is not arbitary chosen.


Heiko
Heiko Stübner March 31, 2016, 5:15 p.m. UTC | #2
Am Samstag, 19. März 2016, 09:04:08 schrieb Heiko Stuebner:
> Am Mittwoch, 16. März 2016, 14:58:39 schrieb Andreas Färber:
> > A dtc update results in warnings for nodes with reg property but without
> > unit address in the node name, so rename /memory to /memory@0.
> > 
> > Signed-off-by: Andreas Färber <afaerber@suse.de>
> 
> applied to a dts64-fixes branch for 4.6, after changing the commit message
> to ----
> A dtc update results in warnings for nodes with reg property but without
> unit address in the node name, so rename /memory to /memory@startaddress
> (memory starts at 0 in the case of the rk3368).
> ----
> 
> To clarify that the @0 is not arbitary chosen.

This dtc update in question hasn't landed in v4.6-rc1 and from what I 
gathered will need some changes. The patch is obviously still correct, but I 
have now moved it from v4.6-fixes to the regular v4.7 64bit dts changes.


Heiko
Heiko Stübner March 31, 2016, 8:45 p.m. UTC | #3
Am Donnerstag, 31. März 2016, 19:15:43 schrieb Heiko Stuebner:
> Am Samstag, 19. März 2016, 09:04:08 schrieb Heiko Stuebner:
> > Am Mittwoch, 16. März 2016, 14:58:39 schrieb Andreas Färber:
> > > A dtc update results in warnings for nodes with reg property but
> > > without
> > > unit address in the node name, so rename /memory to /memory@0.
> > > 
> > > Signed-off-by: Andreas Färber <afaerber@suse.de>
> > 
> > applied to a dts64-fixes branch for 4.6, after changing the commit
> > message to ----
> > A dtc update results in warnings for nodes with reg property but without
> > unit address in the node name, so rename /memory to /memory@startaddress
> > (memory starts at 0 in the case of the rk3368).
> > ----
> > 
> > To clarify that the @0 is not arbitary chosen.
> 
> This dtc update in question hasn't landed in v4.6-rc1 and from what I
> gathered will need some changes. The patch is obviously still correct, but
> I have now moved it from v4.6-fixes to the regular v4.7 64bit dts
> changes.

also it seems "memory" is special and memory without unitname will stay 
allowed [0], especially as uboot or other bootloaders may expect such a node 
to insert the actual amount of memory into it.

Looking at uboot, fdt_fixup_memory_banks seems to look explicitly for a 
"memory" node, so I'm actually not sure, if this is safe to keep at all.


[0] http://www.spinics.net/lists/arm-kernel/msg494038.html
Heiko Stübner April 12, 2016, 5:24 a.m. UTC | #4
Am Donnerstag, 31. März 2016, 22:45:52 schrieb Heiko Stuebner:
> Am Donnerstag, 31. März 2016, 19:15:43 schrieb Heiko Stuebner:
> > Am Samstag, 19. März 2016, 09:04:08 schrieb Heiko Stuebner:
> > > Am Mittwoch, 16. März 2016, 14:58:39 schrieb Andreas Färber:
> > > > A dtc update results in warnings for nodes with reg property but
> > > > without
> > > > unit address in the node name, so rename /memory to /memory@0.
> > > > 
> > > > Signed-off-by: Andreas Färber <afaerber@suse.de>
> > > 
> > > applied to a dts64-fixes branch for 4.6, after changing the commit
> > > message to ----
> > > A dtc update results in warnings for nodes with reg property but
> > > without
> > > unit address in the node name, so rename /memory to
> > > /memory@startaddress
> > > (memory starts at 0 in the case of the rk3368).
> > > ----
> > > 
> > > To clarify that the @0 is not arbitary chosen.
> > 
> > This dtc update in question hasn't landed in v4.6-rc1 and from what I
> > gathered will need some changes. The patch is obviously still correct,
> > but I have now moved it from v4.6-fixes to the regular v4.7 64bit dts
> > changes.
> 
> also it seems "memory" is special and memory without unitname will stay
> allowed [0], especially as uboot or other bootloaders may expect such a
> node to insert the actual amount of memory into it.
> 
> Looking at uboot, fdt_fixup_memory_banks seems to look explicitly for a
> "memory" node, so I'm actually not sure, if this is safe to keep at all.

so after pondering this some more, I decided to drop this change again.
/memory will stay allowed and might produce less issues with bootloaders 
touching the memory values.

> [0] http://www.spinics.net/lists/arm-kernel/msg494038.html
diff mbox

Patch

diff --git a/arch/arm64/boot/dts/rockchip/rk3368-evb.dtsi b/arch/arm64/boot/dts/rockchip/rk3368-evb.dtsi
index 06bbe421db37..e4c91e86e9b6 100644
--- a/arch/arm64/boot/dts/rockchip/rk3368-evb.dtsi
+++ b/arch/arm64/boot/dts/rockchip/rk3368-evb.dtsi
@@ -48,7 +48,7 @@ 
 		stdout-path = "serial2:115200n8";
 	};
 
-	memory {
+	memory@0 {
 		device_type = "memory";
 		reg = <0x0 0x0 0x0 0x40000000>;
 	};
diff --git a/arch/arm64/boot/dts/rockchip/rk3368-r88.dts b/arch/arm64/boot/dts/rockchip/rk3368-r88.dts
index a1d1aa9c16fe..5c63f8982128 100644
--- a/arch/arm64/boot/dts/rockchip/rk3368-r88.dts
+++ b/arch/arm64/boot/dts/rockchip/rk3368-r88.dts
@@ -51,7 +51,7 @@ 
 		stdout-path = "serial2:115200n8";
 	};
 
-	memory {
+	memory@0 {
 		device_type = "memory";
 		reg = <0x0 0x0 0x0 0x40000000>;
 	};