diff mbox series

[OpenWrt-Devel] mediatek: Fix amount of memory on U7623

Message ID 20180806174630.21348-1-kristian.evensen@gmail.com
State Superseded
Delegated to: John Crispin
Headers show
Series [OpenWrt-Devel] mediatek: Fix amount of memory on U7623 | expand

Commit Message

Kristian Evensen Aug. 6, 2018, 5:46 p.m. UTC
While finalizing support for the U7623 with 512MB RAM, I made an embarrassing
error and configured 1GB RAM for the board. I also forgot to move memory
from the dtsi and to the dts. This commit takes care of my errors.

While I am confessing my mistakes, I also note that I made a mistake in
the commit message of the initial U7623 commit. It is the .bin-file, and
not the .gz file that shall be sent to the device via tftp.

Signed-off-by: Kristian Evensen <kristian.evensen@gmail.com>
---
 .../0227-arm-dts-Add-Unielec-U7623-DTS.patch       | 37 +++++++++++++---------
 1 file changed, 22 insertions(+), 15 deletions(-)

Comments

Jonas Gorski Aug. 7, 2018, 8:10 p.m. UTC | #1
On 6 August 2018 at 19:46, Kristian Evensen <kristian.evensen@gmail.com> wrote:
> While finalizing support for the U7623 with 512MB RAM, I made an embarrassing
> error and configured 1GB RAM for the board. I also forgot to move memory
> from the dtsi and to the dts. This commit takes care of my errors.
>
> While I am confessing my mistakes, I also note that I made a mistake in
> the commit message of the initial U7623 commit. It is the .bin-file, and
> not the .gz file that shall be sent to the device via tftp.
>
> Signed-off-by: Kristian Evensen <kristian.evensen@gmail.com>
> ---
>  .../0227-arm-dts-Add-Unielec-U7623-DTS.patch       | 37 +++++++++++++---------
>  1 file changed, 22 insertions(+), 15 deletions(-)
>
> diff --git a/target/linux/mediatek/patches-4.14/0227-arm-dts-Add-Unielec-U7623-DTS.patch b/target/linux/mediatek/patches-4.14/0227-arm-dts-Add-Unielec-U7623-DTS.patch
> index eb864e4657..8c0b7611b6 100644
> --- a/target/linux/mediatek/patches-4.14/0227-arm-dts-Add-Unielec-U7623-DTS.patch
> +++ b/target/linux/mediatek/patches-4.14/0227-arm-dts-Add-Unielec-U7623-DTS.patch
> @@ -1,16 +1,18 @@
> -From 13872b8abfadfe70598c065c19d1db759477c4e6 Mon Sep 17 00:00:00 2001
> +From 1ebcba67d45f1365bcb1b5eb8b0cd8c847610ef2 Mon Sep 17 00:00:00 2001
>  From: Kristian Evensen <kristian.evensen@gmail.com>
>  Date: Sun, 17 Jun 2018 14:41:47 +0200
>  Subject: [PATCH] arm: dts: Add Unielec U7623 DTS
>
>  ---
>   arch/arm/boot/dts/Makefile                         |   1 +
> - .../dts/mt7623a-unielec-u7623-02-emmc-512M.dts     |  17 +
> - .../boot/dts/mt7623a-unielec-u7623-02-emmc.dtsi    | 375 +++++++++++++++++++++
> - 3 files changed, 393 insertions(+)
> + .../dts/mt7623a-unielec-u7623-02-emmc-512M.dts     |  22 ++
> + .../boot/dts/mt7623a-unielec-u7623-02-emmc.dtsi    | 366 +++++++++++++++++++++
> + 3 files changed, 389 insertions(+)
>   create mode 100644 arch/arm/boot/dts/mt7623a-unielec-u7623-02-emmc-512M.dts
>   create mode 100644 arch/arm/boot/dts/mt7623a-unielec-u7623-02-emmc.dtsi
>
> +diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
> +index 3fec84fa0..e685ce9a4 100644
>  --- a/arch/arm/boot/dts/Makefile
>  +++ b/arch/arm/boot/dts/Makefile
>  @@ -1062,6 +1062,7 @@ dtb-$(CONFIG_ARCH_MEDIATEK) += \
> @@ -21,9 +23,12 @@ Subject: [PATCH] arm: dts: Add Unielec U7623 DTS
>         mt7623n-rfb-nand.dtb \
>         mt7623n-bananapi-bpi-r2.dtb \
>         mt8127-moose.dtb \
> +diff --git a/arch/arm/boot/dts/mt7623a-unielec-u7623-02-emmc-512M.dts b/arch/arm/boot/dts/mt7623a-unielec-u7623-02-emmc-512M.dts
> +new file mode 100644
> +index 000000000..6efa6e159
>  --- /dev/null
>  +++ b/arch/arm/boot/dts/mt7623a-unielec-u7623-02-emmc-512M.dts
> -@@ -0,0 +1,17 @@
> +@@ -0,0 +1,22 @@
>  +/*
>  + * Copyright 2018 Kristian Evensen <kristian.evensen@gmail.com>
>  + *
> @@ -40,10 +45,18 @@ Subject: [PATCH] arm: dts: Add Unielec U7623 DTS
>  +      memory {
>  +              reg = <0 0x80000000 0 0x20000000>;
>  +      };
> ++
> ++      memory@80000000 {
> ++              device_type = "memory";
> ++              reg = <0 0x80000000 0 0x20000000>;
> ++      };

You are adding a second memory node with the same register range as
the one directly above here, that looks wrong.


Regards
Jonas
Kristian Evensen Aug. 8, 2018, 4:30 a.m. UTC | #2
Hi Jonas,

On Tue, Aug 7, 2018 at 10:10 PM, Jonas Gorski <jonas.gorski@gmail.com> wrote:
> You are adding a second memory node with the same register range as
> the one directly above here, that looks wrong.

Thanks for noticing. The first memory node is redundant and a
left-over from when mediatek was based on an older kernel, and I had
forgot to remove it. I will submit a v2 where only the second memory
node is present.

BR,
Kristian
diff mbox series

Patch

diff --git a/target/linux/mediatek/patches-4.14/0227-arm-dts-Add-Unielec-U7623-DTS.patch b/target/linux/mediatek/patches-4.14/0227-arm-dts-Add-Unielec-U7623-DTS.patch
index eb864e4657..8c0b7611b6 100644
--- a/target/linux/mediatek/patches-4.14/0227-arm-dts-Add-Unielec-U7623-DTS.patch
+++ b/target/linux/mediatek/patches-4.14/0227-arm-dts-Add-Unielec-U7623-DTS.patch
@@ -1,16 +1,18 @@ 
-From 13872b8abfadfe70598c065c19d1db759477c4e6 Mon Sep 17 00:00:00 2001
+From 1ebcba67d45f1365bcb1b5eb8b0cd8c847610ef2 Mon Sep 17 00:00:00 2001
 From: Kristian Evensen <kristian.evensen@gmail.com>
 Date: Sun, 17 Jun 2018 14:41:47 +0200
 Subject: [PATCH] arm: dts: Add Unielec U7623 DTS
 
 ---
  arch/arm/boot/dts/Makefile                         |   1 +
- .../dts/mt7623a-unielec-u7623-02-emmc-512M.dts     |  17 +
- .../boot/dts/mt7623a-unielec-u7623-02-emmc.dtsi    | 375 +++++++++++++++++++++
- 3 files changed, 393 insertions(+)
+ .../dts/mt7623a-unielec-u7623-02-emmc-512M.dts     |  22 ++
+ .../boot/dts/mt7623a-unielec-u7623-02-emmc.dtsi    | 366 +++++++++++++++++++++
+ 3 files changed, 389 insertions(+)
  create mode 100644 arch/arm/boot/dts/mt7623a-unielec-u7623-02-emmc-512M.dts
  create mode 100644 arch/arm/boot/dts/mt7623a-unielec-u7623-02-emmc.dtsi
 
+diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
+index 3fec84fa0..e685ce9a4 100644
 --- a/arch/arm/boot/dts/Makefile
 +++ b/arch/arm/boot/dts/Makefile
 @@ -1062,6 +1062,7 @@ dtb-$(CONFIG_ARCH_MEDIATEK) += \
@@ -21,9 +23,12 @@  Subject: [PATCH] arm: dts: Add Unielec U7623 DTS
  	mt7623n-rfb-nand.dtb \
  	mt7623n-bananapi-bpi-r2.dtb \
  	mt8127-moose.dtb \
+diff --git a/arch/arm/boot/dts/mt7623a-unielec-u7623-02-emmc-512M.dts b/arch/arm/boot/dts/mt7623a-unielec-u7623-02-emmc-512M.dts
+new file mode 100644
+index 000000000..6efa6e159
 --- /dev/null
 +++ b/arch/arm/boot/dts/mt7623a-unielec-u7623-02-emmc-512M.dts
-@@ -0,0 +1,17 @@
+@@ -0,0 +1,22 @@
 +/*
 + * Copyright 2018 Kristian Evensen <kristian.evensen@gmail.com>
 + *
@@ -40,10 +45,18 @@  Subject: [PATCH] arm: dts: Add Unielec U7623 DTS
 +	memory {
 +		reg = <0 0x80000000 0 0x20000000>;
 +	};
++
++	memory@80000000 {
++		device_type = "memory";
++		reg = <0 0x80000000 0 0x20000000>;
++	};
 +};
+diff --git a/arch/arm/boot/dts/mt7623a-unielec-u7623-02-emmc.dtsi b/arch/arm/boot/dts/mt7623a-unielec-u7623-02-emmc.dtsi
+new file mode 100644
+index 000000000..adc91266e
 --- /dev/null
 +++ b/arch/arm/boot/dts/mt7623a-unielec-u7623-02-emmc.dtsi
-@@ -0,0 +1,375 @@
+@@ -0,0 +1,366 @@
 +/*
 + * Copyright 2018 Kristian Evensen <kristian.evensen@gmail.com>
 + *
@@ -66,10 +79,6 @@  Subject: [PATCH] arm: dts: Add Unielec U7623 DTS
 +		stdout-path = "serial2:115200n8";
 +	};
 +
-+	memory {
-+		reg = <0 0x80000000 0 0x20000000>;
-+	};
-+
 +	cpus {
 +		cpu@0 {
 +			proc-supply = <&mt6323_vproc_reg>;
@@ -145,11 +154,6 @@  Subject: [PATCH] arm: dts: Add Unielec U7623 DTS
 +		};
 +	};
 +
-+	memory@80000000 {
-+		device_type = "memory";
-+		reg = <0 0x80000000 0 0x40000000>;
-+	};
-+
 +	mt7530: switch@0 {
 +		compatible = "mediatek,mt7530";
 +		#address-cells = <1>;
@@ -419,3 +423,6 @@  Subject: [PATCH] arm: dts: Add Unielec U7623 DTS
 +	status = "okay";
 +};
 +
+-- 
+2.14.1
+