]>
Commit | Line | Data |
---|---|---|
0f714131 GKH |
1 | From c0b0d540db1a8bfb041166c4991dd6f624e8de45 Mon Sep 17 00:00:00 2001 |
2 | From: Sean Wang <sean.wang@mediatek.com> | |
3 | Date: Wed, 11 Apr 2018 16:53:56 +0800 | |
4 | Subject: arm: dts: mt7623: fix invalid memory node being generated | |
5 | ||
6 | From: Sean Wang <sean.wang@mediatek.com> | |
7 | ||
8 | commit c0b0d540db1a8bfb041166c4991dd6f624e8de45 upstream. | |
9 | ||
10 | Below two wrong nodes in existing DTS files would cause a fail boot since | |
11 | in fact the address 0 is not the correct place the memory device locates | |
12 | at. | |
13 | ||
14 | memory { | |
15 | device_type = "memory"; | |
16 | reg = <0x0 0x0 0x0 0x0>; | |
17 | }; | |
18 | ||
19 | memory@80000000 { | |
20 | reg = <0x0 0x80000000 0x0 0x40000000>; | |
21 | }; | |
22 | ||
23 | In order to avoid having a memory node starting at address 0, we can't | |
24 | include file skeleton64.dtsi and instead need to explicitly manually | |
25 | define a few of properties the DTS relies on such as #address-cells | |
26 | and #size-cells in root node and device_type in the node memory@80000000. | |
27 | ||
28 | Cc: stable@vger.kernel.org | |
29 | Fixes: 31ac0d69a1d4 ("ARM: dts: mediatek: add MT7623 basic support") | |
30 | Signed-off-by: Sean Wang <sean.wang@mediatek.com> | |
31 | Cc: Rob Herring <robh+dt@kernel.org> | |
32 | Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com> | |
33 | Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> | |
34 | ||
35 | --- | |
36 | arch/arm/boot/dts/mt7623.dtsi | 3 ++- | |
37 | arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts | 1 + | |
38 | arch/arm/boot/dts/mt7623n-rfb.dtsi | 1 + | |
39 | 3 files changed, 4 insertions(+), 1 deletion(-) | |
40 | ||
41 | --- a/arch/arm/boot/dts/mt7623.dtsi | |
42 | +++ b/arch/arm/boot/dts/mt7623.dtsi | |
43 | @@ -22,11 +22,12 @@ | |
44 | #include <dt-bindings/phy/phy.h> | |
45 | #include <dt-bindings/reset/mt2701-resets.h> | |
46 | #include <dt-bindings/thermal/thermal.h> | |
47 | -#include "skeleton64.dtsi" | |
48 | ||
49 | / { | |
50 | compatible = "mediatek,mt7623"; | |
51 | interrupt-parent = <&sysirq>; | |
52 | + #address-cells = <2>; | |
53 | + #size-cells = <2>; | |
54 | ||
55 | cpu_opp_table: opp_table { | |
56 | compatible = "operating-points-v2"; | |
57 | --- a/arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts | |
58 | +++ b/arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts | |
59 | @@ -100,6 +100,7 @@ | |
60 | }; | |
61 | ||
62 | memory@80000000 { | |
63 | + device_type = "memory"; | |
64 | reg = <0 0x80000000 0 0x40000000>; | |
65 | }; | |
66 | }; | |
67 | --- a/arch/arm/boot/dts/mt7623n-rfb.dtsi | |
68 | +++ b/arch/arm/boot/dts/mt7623n-rfb.dtsi | |
69 | @@ -47,6 +47,7 @@ | |
70 | }; | |
71 | ||
72 | memory@80000000 { | |
73 | + device_type = "memory"; | |
74 | reg = <0 0x80000000 0 0x40000000>; | |
75 | }; | |
76 |