diff mbox

[2/2] ARM: dts: berlin2q: add the Marvell BG2-Q DMP device tree

Message ID 1394622364-6848-3-git-send-email-antoine.tenart@free-electrons.com (mailing list archive)
State New, archived
Headers show

Commit Message

Antoine Tenart March 12, 2014, 11:06 a.m. UTC
Signed-off-by: Antoine Ténart <antoine.tenart@free-electrons.com>
---
 arch/arm/boot/dts/Makefile         |  3 ++-
 arch/arm/boot/dts/berlin2q-dmp.dts | 32 ++++++++++++++++++++++++++++++++
 2 files changed, 34 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/boot/dts/berlin2q-dmp.dts

Comments

Arnd Bergmann March 12, 2014, 11:20 a.m. UTC | #1
On Wednesday 12 March 2014 12:06:04 Antoine Ténart wrote:
> +
> +       soc {
> +               apb@fc0000 {
> +                       uart0: uart@9000 {
> +                               status = "okay";
> +                       };
> +               };
> +       };
> +};


No need to duplicate both the label and the hierarchy here. The easiest
way to do this is just

	&uart0 {
		status = "okay";
	};

since you already have the label.

	Arnd
Antoine Tenart March 12, 2014, 11:30 a.m. UTC | #2
On 12/03/2014 12:20, Arnd Bergmann wrote:
> On Wednesday 12 March 2014 12:06:04 Antoine Ténart wrote:
>> +
>> +       soc {
>> +               apb@fc0000 {
>> +                       uart0: uart@9000 {
>> +                               status = "okay";
>> +                       };
>> +               };
>> +       };
>> +};
>
>
> No need to duplicate both the label and the hierarchy here. The easiest
> way to do this is just
>
> 	&uart0 {
> 		status = "okay";
> 	};
>
> since you already have the label.

I'll change that.

Thanks for the feedback !
Jisheng Zhang March 12, 2014, 12:04 p.m. UTC | #3
Hi Antoine,

On Wed, 12 Mar 2014 04:06:04 -0700
Antoine Ténart <antoine.tenart@free-electrons.com> wrote:

> Signed-off-by: Antoine Ténart <antoine.tenart@free-electrons.com>
> ---
>  arch/arm/boot/dts/Makefile         |  3 ++-
>  arch/arm/boot/dts/berlin2q-dmp.dts | 32 ++++++++++++++++++++++++++++++++
>  2 files changed, 34 insertions(+), 1 deletion(-)
>  create mode 100644 arch/arm/boot/dts/berlin2q-dmp.dts
> 
> diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
> index 032030361bef..1a2adadfb962 100644
> --- a/arch/arm/boot/dts/Makefile
> +++ b/arch/arm/boot/dts/Makefile
> @@ -52,7 +52,8 @@ dtb-$(CONFIG_ARCH_BCM_MOBILE) += bcm11351-brt.dtb \
>  dtb-$(CONFIG_ARCH_BCM2835) += bcm2835-rpi-b.dtb
>  dtb-$(CONFIG_ARCH_BERLIN) += \
>  	berlin2-sony-nsz-gs7.dtb	\
> -	berlin2cd-google-chromecast.dtb
> +	berlin2cd-google-chromecast.dtb	\
> +	berlin2q-dmp.dtb
>  dtb-$(CONFIG_ARCH_DAVINCI) += da850-enbw-cmc.dtb \
>  	da850-evm.dtb
>  dtb-$(CONFIG_ARCH_DOVE) += dove-cm-a510.dtb \
> diff --git a/arch/arm/boot/dts/berlin2q-dmp.dts
> b/arch/arm/boot/dts/berlin2q-dmp.dts new file mode 100644
> index 000000000000..6a98860e0251
> --- /dev/null
> +++ b/arch/arm/boot/dts/berlin2q-dmp.dts
> @@ -0,0 +1,32 @@
> +/*
> + * Copyright (C) 2014 Antoine Ténart <antoine.tenart@free-electrons.com>
> + *
> + * This file is licensed under the terms of the GNU General Public
> + * License version 2. This program is licensed "as is" without any
> + * warranty of any kind, whether express or implied.
> + */
> +
> +/dts-v1/;
> +#include "berlin2q.dtsi"
> +
> +/ {
> +	model = "Marvell BG2-Q DMP";
> +	compatible = "marvell,berlin2q-dmp", "marvell,berlin2q",
> "marvell,berlin"; +
> +	memory {
> +		device_type = "memory";
> +		reg = <0x00000000 0x40000000>;

The memory size of BG2Q DMP is 2GB. And IIRC, all BG2Q boards have 2GB memory.
So would it be better to put memory dt node in berlin2q.dtsi?

Thanks,
Jisheng
Andrew Lunn March 12, 2014, 12:37 p.m. UTC | #4
> > +/dts-v1/;
> > +#include "berlin2q.dtsi"
> > +
> > +/ {
> > +	model = "Marvell BG2-Q DMP";
> > +	compatible = "marvell,berlin2q-dmp", "marvell,berlin2q",
> > "marvell,berlin"; +
> > +	memory {
> > +		device_type = "memory";
> > +		reg = <0x00000000 0x40000000>;
> 
> The memory size of BG2Q DMP is 2GB.

Jisheng

Does this imply that the RAM is inside the SoC package, and that
there is no external memory interface which can be used to add more
RAM?

	Thanks
		Andrew
Jisheng Zhang March 12, 2014, 12:44 p.m. UTC | #5
Hi Andrew,

On Wed, 12 Mar 2014 05:37:59 -0700
Andrew Lunn <andrew@lunn.ch> wrote:

> > > +/dts-v1/;
> > > +#include "berlin2q.dtsi"
> > > +
> > > +/ {
> > > +	model = "Marvell BG2-Q DMP";
> > > +	compatible = "marvell,berlin2q-dmp", "marvell,berlin2q",
> > > "marvell,berlin"; +
> > > +	memory {
> > > +		device_type = "memory";
> > > +		reg = <0x00000000 0x40000000>;
> > 
> > The memory size of BG2Q DMP is 2GB.
> 
> Jisheng
> 
> Does this imply that the RAM is inside the SoC package, and that
> there is no external memory interface which can be used to add more
> RAM?

Nope. The ram is on the board. After talking with Alex, I think it's 
reasonable to put the memory node in dts as the original patch does.

However, we need to set the correct memory size of BG2Q DMP board.

Thanks,
Jisheng
Sebastian Hesselbarth March 13, 2014, 10:08 a.m. UTC | #6
On 03/12/2014 11:06 AM, Antoine Ténart wrote:
> Signed-off-by: Antoine Ténart <antoine.tenart@free-electrons.com>
> ---
>   arch/arm/boot/dts/Makefile         |  3 ++-
>   arch/arm/boot/dts/berlin2q-dmp.dts | 32 ++++++++++++++++++++++++++++++++
>   2 files changed, 34 insertions(+), 1 deletion(-)
>   create mode 100644 arch/arm/boot/dts/berlin2q-dmp.dts
>
> diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
> index 032030361bef..1a2adadfb962 100644
> --- a/arch/arm/boot/dts/Makefile
> +++ b/arch/arm/boot/dts/Makefile
> @@ -52,7 +52,8 @@ dtb-$(CONFIG_ARCH_BCM_MOBILE) += bcm11351-brt.dtb \
>   dtb-$(CONFIG_ARCH_BCM2835) += bcm2835-rpi-b.dtb
>   dtb-$(CONFIG_ARCH_BERLIN) += \
>   	berlin2-sony-nsz-gs7.dtb	\
> -	berlin2cd-google-chromecast.dtb
> +	berlin2cd-google-chromecast.dtb	\
> +	berlin2q-dmp.dtb

If it is "the" Marvell reference board, the file should be named
berlin2q-marvell-dmp.dtb.

>   dtb-$(CONFIG_ARCH_DAVINCI) += da850-enbw-cmc.dtb \
>   	da850-evm.dtb
>   dtb-$(CONFIG_ARCH_DOVE) += dove-cm-a510.dtb \
> diff --git a/arch/arm/boot/dts/berlin2q-dmp.dts b/arch/arm/boot/dts/berlin2q-dmp.dts
> new file mode 100644
> index 000000000000..6a98860e0251
> --- /dev/null
> +++ b/arch/arm/boot/dts/berlin2q-dmp.dts
> @@ -0,0 +1,32 @@
> +/*
> + * Copyright (C) 2014 Antoine Ténart <antoine.tenart@free-electrons.com>
> + *
> + * This file is licensed under the terms of the GNU General Public
> + * License version 2. This program is licensed "as is" without any
> + * warranty of any kind, whether express or implied.
> + */
> +
> +/dts-v1/;
> +#include "berlin2q.dtsi"
> +
> +/ {
> +	model = "Marvell BG2-Q DMP";
> +	compatible = "marvell,berlin2q-dmp", "marvell,berlin2q", "marvell,berlin";
> +
> +	memory {
> +		device_type = "memory";
> +		reg = <0x00000000 0x40000000>;

Please double-check Jisheng's comment about memory size.

> +	};
> +
> +	choosen {
> +		bootargs = "console=ttyS0,115200 earlyprintk";
> +	};
> +
> +	soc {
> +		apb@fc0000 {
> +			uart0: uart@9000 {
> +				status = "okay";
> +			};
> +		};
> +	};

And Arnd's comment about using &uart0 instead.

Beside the comments made, this all looks fine.

Sebastian

> +};
>
diff mbox

Patch

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index 032030361bef..1a2adadfb962 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -52,7 +52,8 @@  dtb-$(CONFIG_ARCH_BCM_MOBILE) += bcm11351-brt.dtb \
 dtb-$(CONFIG_ARCH_BCM2835) += bcm2835-rpi-b.dtb
 dtb-$(CONFIG_ARCH_BERLIN) += \
 	berlin2-sony-nsz-gs7.dtb	\
-	berlin2cd-google-chromecast.dtb
+	berlin2cd-google-chromecast.dtb	\
+	berlin2q-dmp.dtb
 dtb-$(CONFIG_ARCH_DAVINCI) += da850-enbw-cmc.dtb \
 	da850-evm.dtb
 dtb-$(CONFIG_ARCH_DOVE) += dove-cm-a510.dtb \
diff --git a/arch/arm/boot/dts/berlin2q-dmp.dts b/arch/arm/boot/dts/berlin2q-dmp.dts
new file mode 100644
index 000000000000..6a98860e0251
--- /dev/null
+++ b/arch/arm/boot/dts/berlin2q-dmp.dts
@@ -0,0 +1,32 @@ 
+/*
+ * Copyright (C) 2014 Antoine Ténart <antoine.tenart@free-electrons.com>
+ *
+ * This file is licensed under the terms of the GNU General Public
+ * License version 2. This program is licensed "as is" without any
+ * warranty of any kind, whether express or implied.
+ */
+
+/dts-v1/;
+#include "berlin2q.dtsi"
+
+/ {
+	model = "Marvell BG2-Q DMP";
+	compatible = "marvell,berlin2q-dmp", "marvell,berlin2q", "marvell,berlin";
+
+	memory {
+		device_type = "memory";
+		reg = <0x00000000 0x40000000>;
+	};
+
+	choosen {
+		bootargs = "console=ttyS0,115200 earlyprintk";
+	};
+
+	soc {
+		apb@fc0000 {
+			uart0: uart@9000 {
+				status = "okay";
+			};
+		};
+	};
+};