linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
@ 2012-10-23  8:19 Thomas Petazzoni
  2012-10-23  8:42 ` Andrew Lunn
                   ` (3 more replies)
  0 siblings, 4 replies; 17+ messages in thread
From: Thomas Petazzoni @ 2012-10-23  8:19 UTC (permalink / raw)
  To: linux-arm-kernel

This platform, available in Japan from PlatHome, has a dual-core
Armada XP, the MV78260. For now, only the two serial ports and the
three front LEDs are supported. Support for network, SATA, USB and
other peripherals will be added as drivers for them become available
for Armada XP in mainline.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>

---
This is 3.8 material.
---
 arch/arm/boot/dts/Makefile           |    3 +-
 arch/arm/boot/dts/openblocks-ax3.dts |   69 ++++++++++++++++++++++++++++++++++
 arch/arm/mach-mvebu/armada-370-xp.c  |    1 +
 3 files changed, 72 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/boot/dts/openblocks-ax3.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index f37cf9f..b7814b9 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -44,7 +44,8 @@ dtb-$(CONFIG_ARCH_KIRKWOOD) += kirkwood-dns320.dtb \
 dtb-$(CONFIG_ARCH_MSM) += msm8660-surf.dtb \
 	msm8960-cdp.dtb
 dtb-$(CONFIG_ARCH_MVEBU) += armada-370-db.dtb \
-	armada-xp-db.dtb
+	armada-xp-db.dtb \
+	openblocks-ax3.dtb
 dtb-$(CONFIG_ARCH_MXC) += imx51-babbage.dtb \
 	imx53-ard.dtb \
 	imx53-evk.dtb \
diff --git a/arch/arm/boot/dts/openblocks-ax3.dts b/arch/arm/boot/dts/openblocks-ax3.dts
new file mode 100644
index 0000000..f757116
--- /dev/null
+++ b/arch/arm/boot/dts/openblocks-ax3.dts
@@ -0,0 +1,69 @@
+/*
+ * Device Tree file for OpenBlocks AX3 board
+ *
+ * Copyright (C) 2012 Marvell
+ *
+ * Thomas Petazzoni <thomas.petazzoni@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/ "armada-xp-mv78260.dtsi"
+
+/ {
+	model = "PlatHome OpenBlocks AX3 board";
+	compatible = "plathome,openblocks-ax3", "marvell,armadaxp-mv78260", "marvell,armadaxp", "marvell,armada-370-xp";
+
+	chosen {
+		bootargs = "console=ttyS0,115200 earlyprintk";
+	};
+
+	memory {
+		device_type = "memory";
+		reg = <0x00000000 0x40000000>; /* 1 GB */
+	};
+
+	soc {
+		serial at d0012000 {
+			clock-frequency = <250000000>;
+			status = "okay";
+		};
+		serial at d0012100 {
+			clock-frequency = <250000000>;
+			status = "okay";
+		};
+		pinctrl {
+			led_pins: led-pins-0 {
+				  marvell,pins = "mpp49", "mpp51", "mpp53";
+				  marvell,function = "gpio";
+			};
+		};
+		leds {
+		        compatible = "gpio-leds";
+			pinctrl-names = "default";
+			pinctrl-0 = <&led_pins>;
+
+			red_led {
+				   label = "red_led";
+				   gpios = <&gpio1 17 1>;
+				   default-state = "off";
+			};
+
+			yellow_led {
+				   label = "yellow_led";
+				   gpios = <&gpio1 19 1>;
+				   default-state = "off";
+			};
+
+			green_led {
+				   label = "green_led";
+				   gpios = <&gpio1 21 1>;
+				   default-state = "off";
+				   linux,default-trigger = "heartbeat";
+			};
+		};
+	};
+};
diff --git a/arch/arm/mach-mvebu/armada-370-xp.c b/arch/arm/mach-mvebu/armada-370-xp.c
index 49d7915..cd2717b 100644
--- a/arch/arm/mach-mvebu/armada-370-xp.c
+++ b/arch/arm/mach-mvebu/armada-370-xp.c
@@ -49,6 +49,7 @@ static void __init armada_370_xp_dt_init(void)
 static const char * const armada_370_xp_dt_board_dt_compat[] = {
 	"marvell,a370-db",
 	"marvell,axp-db",
+	"plathome,openblocks-ax3",
 	NULL,
 };
 
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-10-23  8:19 [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board Thomas Petazzoni
@ 2012-10-23  8:42 ` Andrew Lunn
  2012-10-23  8:45   ` Thomas Petazzoni
  2012-10-24  8:58 ` Gregory CLEMENT
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 17+ messages in thread
From: Andrew Lunn @ 2012-10-23  8:42 UTC (permalink / raw)
  To: linux-arm-kernel

> diff --git a/arch/arm/mach-mvebu/armada-370-xp.c b/arch/arm/mach-mvebu/armada-370-xp.c
> index 49d7915..cd2717b 100644
> --- a/arch/arm/mach-mvebu/armada-370-xp.c
> +++ b/arch/arm/mach-mvebu/armada-370-xp.c
> @@ -49,6 +49,7 @@ static void __init armada_370_xp_dt_init(void)
>  static const char * const armada_370_xp_dt_board_dt_compat[] = {
>  	"marvell,a370-db",
>  	"marvell,axp-db",
> +	"plathome,openblocks-ax3",
>  	NULL,
>  };

Hi Thomas

You will get less merge conflicts with new boards if you keep this
list sorted.

    Andrew

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-10-23  8:42 ` Andrew Lunn
@ 2012-10-23  8:45   ` Thomas Petazzoni
  2012-10-23 11:16     ` Jason Cooper
  0 siblings, 1 reply; 17+ messages in thread
From: Thomas Petazzoni @ 2012-10-23  8:45 UTC (permalink / raw)
  To: linux-arm-kernel

Dear Andrew Lunn,

On Tue, 23 Oct 2012 10:42:41 +0200, Andrew Lunn wrote:
> > diff --git a/arch/arm/mach-mvebu/armada-370-xp.c b/arch/arm/mach-mvebu/armada-370-xp.c
> > index 49d7915..cd2717b 100644
> > --- a/arch/arm/mach-mvebu/armada-370-xp.c
> > +++ b/arch/arm/mach-mvebu/armada-370-xp.c
> > @@ -49,6 +49,7 @@ static void __init armada_370_xp_dt_init(void)
> >  static const char * const armada_370_xp_dt_board_dt_compat[] = {
> >  	"marvell,a370-db",
> >  	"marvell,axp-db",
> > +	"plathome,openblocks-ax3",
> >  	NULL,
> >  };
> 
> Hi Thomas
> 
> You will get less merge conflicts with new boards if you keep this
> list sorted.

Hum, right, but isn't "plathome" after "marvell" when sorted
alphabetically? Or maybe I don't get which kind of sorting you are
referring to?

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-10-23  8:45   ` Thomas Petazzoni
@ 2012-10-23 11:16     ` Jason Cooper
  0 siblings, 0 replies; 17+ messages in thread
From: Jason Cooper @ 2012-10-23 11:16 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Oct 23, 2012 at 10:45:34AM +0200, Thomas Petazzoni wrote:
> Dear Andrew Lunn,
> 
> On Tue, 23 Oct 2012 10:42:41 +0200, Andrew Lunn wrote:
> > > diff --git a/arch/arm/mach-mvebu/armada-370-xp.c b/arch/arm/mach-mvebu/armada-370-xp.c
> > > index 49d7915..cd2717b 100644
> > > --- a/arch/arm/mach-mvebu/armada-370-xp.c
> > > +++ b/arch/arm/mach-mvebu/armada-370-xp.c
> > > @@ -49,6 +49,7 @@ static void __init armada_370_xp_dt_init(void)
> > >  static const char * const armada_370_xp_dt_board_dt_compat[] = {
> > >  	"marvell,a370-db",
> > >  	"marvell,axp-db",
> > > +	"plathome,openblocks-ax3",
> > >  	NULL,
> > >  };
> > 
> > Hi Thomas
> > 
> > You will get less merge conflicts with new boards if you keep this
> > list sorted.
> 
> Hum, right, but isn't "plathome" after "marvell" when sorted
> alphabetically? Or maybe I don't get which kind of sorting you are
> referring to?

No, no, no.  marvell, /then/ NULL, /then/ plathome.  ;-)  Right, Andrew?

thx,

Jason.

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-10-23  8:19 [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board Thomas Petazzoni
  2012-10-23  8:42 ` Andrew Lunn
@ 2012-10-24  8:58 ` Gregory CLEMENT
  2012-10-24 14:15   ` Thomas Petazzoni
  2012-10-24 15:06 ` Andrew Lunn
  2012-10-24 19:33 ` [PATCH v2] arm: mvebu: support for the PlatHome OpenBlocks AX3-4 board Thomas Petazzoni
  3 siblings, 1 reply; 17+ messages in thread
From: Gregory CLEMENT @ 2012-10-24  8:58 UTC (permalink / raw)
  To: linux-arm-kernel

On 10/23/2012 10:19 AM, Thomas Petazzoni wrote:
> This platform, available in Japan from PlatHome, has a dual-core
> Armada XP, the MV78260. For now, only the two serial ports and the
> three front LEDs are supported. Support for network, SATA, USB and
> other peripherals will be added as drivers for them become available
> for Armada XP in mainline.
And don't forget the SMP support too, MV78260 is supposed to have 2 cores.

Besides this, this patch looks good. I have applied it on a v3.7-rc2
without any problem, and managed to build it also.
So you can add my
Acked-by: Gregory CLEMENT <gregory.clement@free-electrons.com>


> 
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
> 
> ---
> This is 3.8 material.
> ---
>  arch/arm/boot/dts/Makefile           |    3 +-
>  arch/arm/boot/dts/openblocks-ax3.dts |   69 ++++++++++++++++++++++++++++++++++
>  arch/arm/mach-mvebu/armada-370-xp.c  |    1 +
>  3 files changed, 72 insertions(+), 1 deletion(-)
>  create mode 100644 arch/arm/boot/dts/openblocks-ax3.dts
> 
> diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
> index f37cf9f..b7814b9 100644
> --- a/arch/arm/boot/dts/Makefile
> +++ b/arch/arm/boot/dts/Makefile
> @@ -44,7 +44,8 @@ dtb-$(CONFIG_ARCH_KIRKWOOD) += kirkwood-dns320.dtb \
>  dtb-$(CONFIG_ARCH_MSM) += msm8660-surf.dtb \
>  	msm8960-cdp.dtb
>  dtb-$(CONFIG_ARCH_MVEBU) += armada-370-db.dtb \
> -	armada-xp-db.dtb
> +	armada-xp-db.dtb \
> +	openblocks-ax3.dtb
>  dtb-$(CONFIG_ARCH_MXC) += imx51-babbage.dtb \
>  	imx53-ard.dtb \
>  	imx53-evk.dtb \
> diff --git a/arch/arm/boot/dts/openblocks-ax3.dts b/arch/arm/boot/dts/openblocks-ax3.dts
> new file mode 100644
> index 0000000..f757116
> --- /dev/null
> +++ b/arch/arm/boot/dts/openblocks-ax3.dts
> @@ -0,0 +1,69 @@
> +/*
> + * Device Tree file for OpenBlocks AX3 board
> + *
> + * Copyright (C) 2012 Marvell
> + *
> + * Thomas Petazzoni <thomas.petazzoni@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/ "armada-xp-mv78260.dtsi"
> +
> +/ {
> +	model = "PlatHome OpenBlocks AX3 board";
> +	compatible = "plathome,openblocks-ax3", "marvell,armadaxp-mv78260", "marvell,armadaxp", "marvell,armada-370-xp";
> +
> +	chosen {
> +		bootargs = "console=ttyS0,115200 earlyprintk";
> +	};
> +
> +	memory {
> +		device_type = "memory";
> +		reg = <0x00000000 0x40000000>; /* 1 GB */
> +	};
> +
> +	soc {
> +		serial at d0012000 {
> +			clock-frequency = <250000000>;
> +			status = "okay";
> +		};
> +		serial at d0012100 {
> +			clock-frequency = <250000000>;
> +			status = "okay";
> +		};
> +		pinctrl {
> +			led_pins: led-pins-0 {
> +				  marvell,pins = "mpp49", "mpp51", "mpp53";
> +				  marvell,function = "gpio";
> +			};
> +		};
> +		leds {
> +		        compatible = "gpio-leds";
> +			pinctrl-names = "default";
> +			pinctrl-0 = <&led_pins>;
> +
> +			red_led {
> +				   label = "red_led";
> +				   gpios = <&gpio1 17 1>;
> +				   default-state = "off";
> +			};
> +
> +			yellow_led {
> +				   label = "yellow_led";
> +				   gpios = <&gpio1 19 1>;
> +				   default-state = "off";
> +			};
> +
> +			green_led {
> +				   label = "green_led";
> +				   gpios = <&gpio1 21 1>;
> +				   default-state = "off";
> +				   linux,default-trigger = "heartbeat";
> +			};
> +		};
> +	};
> +};
> diff --git a/arch/arm/mach-mvebu/armada-370-xp.c b/arch/arm/mach-mvebu/armada-370-xp.c
> index 49d7915..cd2717b 100644
> --- a/arch/arm/mach-mvebu/armada-370-xp.c
> +++ b/arch/arm/mach-mvebu/armada-370-xp.c
> @@ -49,6 +49,7 @@ static void __init armada_370_xp_dt_init(void)
>  static const char * const armada_370_xp_dt_board_dt_compat[] = {
>  	"marvell,a370-db",
>  	"marvell,axp-db",
> +	"plathome,openblocks-ax3",
>  	NULL,
>  };
>  
> 


-- 
Gregory Clement, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-10-24  8:58 ` Gregory CLEMENT
@ 2012-10-24 14:15   ` Thomas Petazzoni
  0 siblings, 0 replies; 17+ messages in thread
From: Thomas Petazzoni @ 2012-10-24 14:15 UTC (permalink / raw)
  To: linux-arm-kernel

Dear Gregory CLEMENT,

On Wed, 24 Oct 2012 10:58:02 +0200, Gregory CLEMENT wrote:
> On 10/23/2012 10:19 AM, Thomas Petazzoni wrote:
> > This platform, available in Japan from PlatHome, has a dual-core
> > Armada XP, the MV78260. For now, only the two serial ports and the
> > three front LEDs are supported. Support for network, SATA, USB and
> > other peripherals will be added as drivers for them become available
> > for Armada XP in mainline.
> And don't forget the SMP support too, MV78260 is supposed to have 2 cores.

Sure. My plan is to progressively add support for other devices and
features (SMP included) as we get them merged in mainline.

> Besides this, this patch looks good. I have applied it on a v3.7-rc2
> without any problem, and managed to build it also.
> So you can add my
> Acked-by: Gregory CLEMENT <gregory.clement@free-electrons.com>

Thanks!

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-10-23  8:19 [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board Thomas Petazzoni
  2012-10-23  8:42 ` Andrew Lunn
  2012-10-24  8:58 ` Gregory CLEMENT
@ 2012-10-24 15:06 ` Andrew Lunn
  2012-10-24 15:20   ` Thomas Petazzoni
  2012-10-24 19:33 ` [PATCH v2] arm: mvebu: support for the PlatHome OpenBlocks AX3-4 board Thomas Petazzoni
  3 siblings, 1 reply; 17+ messages in thread
From: Andrew Lunn @ 2012-10-24 15:06 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Oct 23, 2012 at 10:19:25AM +0200, Thomas Petazzoni wrote:
> This platform, available in Japan from PlatHome, has a dual-core
> Armada XP, the MV78260. For now, only the two serial ports and the
> three front LEDs are supported. Support for network, SATA, USB and
> other peripherals will be added as drivers for them become available
> for Armada XP in mainline.
> 
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
> 
> ---
> This is 3.8 material.
> ---
>  arch/arm/boot/dts/Makefile           |    3 +-
>  arch/arm/boot/dts/openblocks-ax3.dts |   69 ++++++++++++++++++++++++++++++++++
>  arch/arm/mach-mvebu/armada-370-xp.c  |    1 +
>  3 files changed, 72 insertions(+), 1 deletion(-)
>  create mode 100644 arch/arm/boot/dts/openblocks-ax3.dts
> 
> diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
> index f37cf9f..b7814b9 100644
> --- a/arch/arm/boot/dts/Makefile
> +++ b/arch/arm/boot/dts/Makefile
> @@ -44,7 +44,8 @@ dtb-$(CONFIG_ARCH_KIRKWOOD) += kirkwood-dns320.dtb \
>  dtb-$(CONFIG_ARCH_MSM) += msm8660-surf.dtb \
>  	msm8960-cdp.dtb
>  dtb-$(CONFIG_ARCH_MVEBU) += armada-370-db.dtb \
> -	armada-xp-db.dtb
> +	armada-xp-db.dtb \
> +	openblocks-ax3.dtb
>  dtb-$(CONFIG_ARCH_MXC) += imx51-babbage.dtb \
>  	imx53-ard.dtb \
>  	imx53-evk.dtb \
> diff --git a/arch/arm/boot/dts/openblocks-ax3.dts b/arch/arm/boot/dts/openblocks-ax3.dts
> new file mode 100644
> index 0000000..f757116
> --- /dev/null
> +++ b/arch/arm/boot/dts/openblocks-ax3.dts
> @@ -0,0 +1,69 @@
> +/*
> + * Device Tree file for OpenBlocks AX3 board
> + *
> + * Copyright (C) 2012 Marvell
> + *
> + * Thomas Petazzoni <thomas.petazzoni@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/ "armada-xp-mv78260.dtsi"
> +
> +/ {
> +	model = "PlatHome OpenBlocks AX3 board";
> +	compatible = "plathome,openblocks-ax3", "marvell,armadaxp-mv78260", "marvell,armadaxp", "marvell,armada-370-xp";
> +
> +	chosen {
> +		bootargs = "console=ttyS0,115200 earlyprintk";
> +	};
> +
> +	memory {
> +		device_type = "memory";
> +		reg = <0x00000000 0x40000000>; /* 1 GB */
> +	};

Hi Thomas

There are two variants of this box, ax3/2 and ax3/4. The ax3/4 can
have more RAM and has a mini pci express slot. Do you expect both
boards to be supported with one dts file?

Thanks
	Andrew

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-10-24 15:06 ` Andrew Lunn
@ 2012-10-24 15:20   ` Thomas Petazzoni
  2012-10-24 15:31     ` Andrew Lunn
  2012-11-26  9:18     ` Hector Oron
  0 siblings, 2 replies; 17+ messages in thread
From: Thomas Petazzoni @ 2012-10-24 15:20 UTC (permalink / raw)
  To: linux-arm-kernel

Andrew,

On Wed, 24 Oct 2012 17:06:14 +0200, Andrew Lunn wrote:

> There are two variants of this box, ax3/2 and ax3/4. The ax3/4 can
> have more RAM and has a mini pci express slot. Do you expect both
> boards to be supported with one dts file?

I have the ax3/4 version apparently.

So, we can have the following possible schemes:

 + openblocks-ax3.dtsi
   + openblocks-ax3-2.dts
   + openblocks-ax3-4.dts

But I am not sure if using a .dtsi to factorize things common between
multiple boards is OK. Or we can do:

 + openblocks-ax3-2.dts
   + openblocks-ax3-4.dts

With openblocks-ax3-4.dts being the simple addition of PCIe slot + more
RAM. That said, I don't have the ax3/2 board anyway, so should we plan
for something that nobody can test at the moment, or wait for someone
to get a ax3/2 board, and therefore be able to do the testing? I think
I prefer to submit dts files that are know to work and have been tested
on hardware that we have.

Best regards,

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-10-24 15:20   ` Thomas Petazzoni
@ 2012-10-24 15:31     ` Andrew Lunn
  2012-10-24 15:35       ` Thomas Petazzoni
  2012-11-26  9:18     ` Hector Oron
  1 sibling, 1 reply; 17+ messages in thread
From: Andrew Lunn @ 2012-10-24 15:31 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, Oct 24, 2012 at 05:20:50PM +0200, Thomas Petazzoni wrote:
> Andrew,
> 
> On Wed, 24 Oct 2012 17:06:14 +0200, Andrew Lunn wrote:
> 
> > There are two variants of this box, ax3/2 and ax3/4. The ax3/4 can
> > have more RAM and has a mini pci express slot. Do you expect both
> > boards to be supported with one dts file?
> 
> I have the ax3/4 version apparently.
> 
> So, we can have the following possible schemes:
> 
>  + openblocks-ax3.dtsi
>    + openblocks-ax3-2.dts
>    + openblocks-ax3-4.dts
> 
> But I am not sure if using a .dtsi to factorize things common between
> multiple boards is OK. Or we can do:
> 
>  + openblocks-ax3-2.dts
>    + openblocks-ax3-4.dts
> 
> With openblocks-ax3-4.dts being the simple addition of PCIe slot + more
> RAM. That said, I don't have the ax3/2 board anyway, so should we plan
> for something that nobody can test at the moment, or wait for someone
> to get a ax3/2 board, and therefore be able to do the testing? I think
> I prefer to submit dts files that are know to work and have been tested
> on hardware that we have.

Hi Thomas

I agree with the last point. So maybe have a openblocks-ax3-4.dts and
set the compatibility string to plathome,openblocks-ax3-4. 

When somebody gets a ax3/2, they can refactor the common DT into a
dtsi file without causing any compatibility issues.

     Andrew

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-10-24 15:31     ` Andrew Lunn
@ 2012-10-24 15:35       ` Thomas Petazzoni
  0 siblings, 0 replies; 17+ messages in thread
From: Thomas Petazzoni @ 2012-10-24 15:35 UTC (permalink / raw)
  To: linux-arm-kernel

Andrew,

On Wed, 24 Oct 2012 17:31:31 +0200, Andrew Lunn wrote:

> I agree with the last point. So maybe have a openblocks-ax3-4.dts and
> set the compatibility string to plathome,openblocks-ax3-4. 
> 
> When somebody gets a ax3/2, they can refactor the common DT into a
> dtsi file without causing any compatibility issues.

Ok, I'll repost with this update. Thanks!

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH v2] arm: mvebu: support for the PlatHome OpenBlocks AX3-4 board
  2012-10-23  8:19 [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board Thomas Petazzoni
                   ` (2 preceding siblings ...)
  2012-10-24 15:06 ` Andrew Lunn
@ 2012-10-24 19:33 ` Thomas Petazzoni
  2012-11-05 17:48   ` Olof Johansson
  3 siblings, 1 reply; 17+ messages in thread
From: Thomas Petazzoni @ 2012-10-24 19:33 UTC (permalink / raw)
  To: linux-arm-kernel

This platform, available in Japan from PlatHome, has a dual-core
Armada XP, the MV78260. For now, only the two serial ports and the
three front LEDs are supported. Support for SMP, network, SATA, USB
and other peripherals will be added as drivers for them become
available for Armada XP in mainline.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>

---
This is 3.8 material.

Changes since v1:

 * Renamed the board to OpenBlocks AX3-4, since there is a variant
   called AX3-2 which has less RAM, and no mini PCIe port. Requested
   by Andrew Lunn.

 * Fix the amount of memory to 3 GB. In fact, the board has 1 GB
   soldered, and 2 GB in a SODIMM slot (which is therefore
   removable). But as the board is delivered as is, we'll assume it
   has 3 GB of memory by default.
---
 arch/arm/boot/dts/Makefile             |    3 +-
 arch/arm/boot/dts/openblocks-ax3-4.dts |   69 ++++++++++++++++++++++++++++++++
 arch/arm/mach-mvebu/armada-370-xp.c    |    1 +
 3 files changed, 72 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/boot/dts/openblocks-ax3-4.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index f37cf9f..6f2a25d 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -44,7 +44,8 @@ dtb-$(CONFIG_ARCH_KIRKWOOD) += kirkwood-dns320.dtb \
 dtb-$(CONFIG_ARCH_MSM) += msm8660-surf.dtb \
 	msm8960-cdp.dtb
 dtb-$(CONFIG_ARCH_MVEBU) += armada-370-db.dtb \
-	armada-xp-db.dtb
+	armada-xp-db.dtb \
+	openblocks-ax3-4.dtb
 dtb-$(CONFIG_ARCH_MXC) += imx51-babbage.dtb \
 	imx53-ard.dtb \
 	imx53-evk.dtb \
diff --git a/arch/arm/boot/dts/openblocks-ax3-4.dts b/arch/arm/boot/dts/openblocks-ax3-4.dts
new file mode 100644
index 0000000..7ef8052
--- /dev/null
+++ b/arch/arm/boot/dts/openblocks-ax3-4.dts
@@ -0,0 +1,69 @@
+/*
+ * Device Tree file for OpenBlocks AX3-4 board
+ *
+ * Copyright (C) 2012 Marvell
+ *
+ * Thomas Petazzoni <thomas.petazzoni@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/ "armada-xp-mv78260.dtsi"
+
+/ {
+	model = "PlatHome OpenBlocks AX3-4 board";
+	compatible = "plathome,openblocks-ax3-4", "marvell,armadaxp-mv78260", "marvell,armadaxp", "marvell,armada-370-xp";
+
+	chosen {
+		bootargs = "console=ttyS0,115200 earlyprintk";
+	};
+
+	memory {
+		device_type = "memory";
+		reg = <0x00000000 0xC0000000>; /* 3 GB */
+	};
+
+	soc {
+		serial at d0012000 {
+			clock-frequency = <250000000>;
+			status = "okay";
+		};
+		serial at d0012100 {
+			clock-frequency = <250000000>;
+			status = "okay";
+		};
+		pinctrl {
+			led_pins: led-pins-0 {
+				  marvell,pins = "mpp49", "mpp51", "mpp53";
+				  marvell,function = "gpio";
+			};
+		};
+		leds {
+		        compatible = "gpio-leds";
+			pinctrl-names = "default";
+			pinctrl-0 = <&led_pins>;
+
+			red_led {
+				   label = "red_led";
+				   gpios = <&gpio1 17 1>;
+				   default-state = "off";
+			};
+
+			yellow_led {
+				   label = "yellow_led";
+				   gpios = <&gpio1 19 1>;
+				   default-state = "off";
+			};
+
+			green_led {
+				   label = "green_led";
+				   gpios = <&gpio1 21 1>;
+				   default-state = "off";
+				   linux,default-trigger = "heartbeat";
+			};
+		};
+	};
+};
diff --git a/arch/arm/mach-mvebu/armada-370-xp.c b/arch/arm/mach-mvebu/armada-370-xp.c
index 49d7915..68f1483 100644
--- a/arch/arm/mach-mvebu/armada-370-xp.c
+++ b/arch/arm/mach-mvebu/armada-370-xp.c
@@ -49,6 +49,7 @@ static void __init armada_370_xp_dt_init(void)
 static const char * const armada_370_xp_dt_board_dt_compat[] = {
 	"marvell,a370-db",
 	"marvell,axp-db",
+	"plathome,openblocks-ax3-4",
 	NULL,
 };
 
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 17+ messages in thread

* [PATCH v2] arm: mvebu: support for the PlatHome OpenBlocks AX3-4 board
  2012-10-24 19:33 ` [PATCH v2] arm: mvebu: support for the PlatHome OpenBlocks AX3-4 board Thomas Petazzoni
@ 2012-11-05 17:48   ` Olof Johansson
  0 siblings, 0 replies; 17+ messages in thread
From: Olof Johansson @ 2012-11-05 17:48 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, Oct 24, 2012 at 09:33:23PM +0200, Thomas Petazzoni wrote:

> +	compatible = "plathome,openblocks-ax3-4", "marvell,armadaxp-mv78260", "marvell,armadaxp", "marvell,armada-370-xp";

[...]

> diff --git a/arch/arm/mach-mvebu/armada-370-xp.c b/arch/arm/mach-mvebu/armada-370-xp.c
> index 49d7915..68f1483 100644
> --- a/arch/arm/mach-mvebu/armada-370-xp.c
> +++ b/arch/arm/mach-mvebu/armada-370-xp.c
> @@ -49,6 +49,7 @@ static void __init armada_370_xp_dt_init(void)
>  static const char * const armada_370_xp_dt_board_dt_compat[] = {
>  	"marvell,a370-db",
>  	"marvell,axp-db",
> +	"plathome,openblocks-ax3-4",
>  	NULL,
>  };

Hi,

One of the big benefits of device trees is to, in a perfect world, having to avoid
adding new C code for a new board.  It seems like this compatible array should
contain one of the more generic compatible fields instead, and you should then
have each board dts specify that as a fallback. It looks like you already list
those in the board dts file, so you're good at that end.

Would that work?

Also, I can't tell for sure but it seems like the list of compatibles in the
board dts go from specific to generic, i.e. if "marvell,armadaxp" is less
generic than "marvell,armada-370-xp".

-Olof

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-10-24 15:20   ` Thomas Petazzoni
  2012-10-24 15:31     ` Andrew Lunn
@ 2012-11-26  9:18     ` Hector Oron
  2012-11-26  9:25       ` Thomas Petazzoni
  1 sibling, 1 reply; 17+ messages in thread
From: Hector Oron @ 2012-11-26  9:18 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

2012/10/24 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>:

> With openblocks-ax3-4.dts being the simple addition of PCIe slot + more
> RAM. That said, I don't have the ax3/2 board anyway, so should we plan
> for something that nobody can test at the moment, or wait for someone
> to get a ax3/2 board, and therefore be able to do the testing? I think
> I prefer to submit dts files that are know to work and have been tested
> on hardware that we have.

I got an ax3/2 device, I would not mind to test any changes? Are you
aware of which changes should I apply to dtsi file to work on ax3-2
device?

regards,
-- 
 H?ctor Or?n  -.. . -... .. .- -.   -.. . ...- . .-.. --- .--. . .-.

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-11-26  9:18     ` Hector Oron
@ 2012-11-26  9:25       ` Thomas Petazzoni
  2012-11-27 13:00         ` Jason Cooper
  0 siblings, 1 reply; 17+ messages in thread
From: Thomas Petazzoni @ 2012-11-26  9:25 UTC (permalink / raw)
  To: linux-arm-kernel

Dear Hector Oron,

On Mon, 26 Nov 2012 10:18:47 +0100, Hector Oron wrote:

> I got an ax3/2 device, I would not mind to test any changes? Are you
> aware of which changes should I apply to dtsi file to work on ax3-2
> device?

If I'm correct, the differences between AX-2 and AX3-4 is:

 * AX3-2 has two Ethernet interfaces, while AX3-4 has four Ethernet
   interfaces

 * AX3-4 is in standard mounted with a 2 GB additional DRAM in a
   SO-DIMM slot, while the AX3-2 is not. However, it is not clear if
   the SO-DIMM slot is present or not on the AX3-2 (could you confirm
   this?).

 * AX3-2 does not have a mini PCIe slot, while AX3-4 has one.

So I guess you could create a separate armada-xp-openblocks-ax3-2.dts
file to support this new board. Maybe at some point it will make sense
to have a common armada-xp-openblocks-ax3.dtsi that both board .dts
includes.

Best regards,

Thomas
-- 
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-11-26  9:25       ` Thomas Petazzoni
@ 2012-11-27 13:00         ` Jason Cooper
  2012-11-28  2:45           ` Mio Watanabe
  0 siblings, 1 reply; 17+ messages in thread
From: Jason Cooper @ 2012-11-27 13:00 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Nov 26, 2012 at 10:25:35AM +0100, Thomas Petazzoni wrote:
> On Mon, 26 Nov 2012 10:18:47 +0100, Hector Oron wrote:
> 
> > I got an ax3/2 device, I would not mind to test any changes? Are you
> > aware of which changes should I apply to dtsi file to work on ax3-2
> > device?
> 
> If I'm correct, the differences between AX-2 and AX3-4 is:
> 
>  * AX3-2 has two Ethernet interfaces, while AX3-4 has four Ethernet
>    interfaces
> 
>  * AX3-4 is in standard mounted with a 2 GB additional DRAM in a
>    SO-DIMM slot, while the AX3-2 is not. However, it is not clear if
>    the SO-DIMM slot is present or not on the AX3-2 (could you confirm
>    this?).
> 
>  * AX3-2 does not have a mini PCIe slot, while AX3-4 has one.
> 
> So I guess you could create a separate armada-xp-openblocks-ax3-2.dts
> file to support this new board. Maybe at some point it will make sense
> to have a common armada-xp-openblocks-ax3.dtsi that both board .dts
> includes.

Adding plathome to the email list to see if they can offer any
concrete answers.

thx,

Jason.

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-11-27 13:00         ` Jason Cooper
@ 2012-11-28  2:45           ` Mio Watanabe
  2012-12-16 16:18             ` Hector Oron
  0 siblings, 1 reply; 17+ messages in thread
From: Mio Watanabe @ 2012-11-28  2:45 UTC (permalink / raw)
  To: linux-arm-kernel

Dear Jason and all,

Thank you for adding us to the email list.

Thomas is correct. The differences between AX3-2 and AX3-4 are only 3 as following.


                                                    AX3-2                   AX3-4  
No. of ethernet interface                2                           4
SO-DIMM slot                                none                       1                            
mini PCIe slot                                none                       1



I delite Mr. Matumoto from the list since he quit Plat'Home already and
I am his successor. Please just remain "eg@". It is a mailing list
including our development section. Thank you.

Kind regards,
Mio Watanabe

????????????????????????
Plat'Home Co., Ltd.
Product Marketing Dept.
Nihon Building Kudanbekkan 3F
4-1-3 Kudankita, Chiyoda-ku, Tokyo
102-0073 Japan
TEL: ++81 (0) 3 5213 4373
FAX: ++81 (0) 3 3221-0882
E-mail : m-watanabe at plathome.co.jp



On Tue, 27 Nov 2012 08:00:35 -0500
Jason Cooper <jason@lakedaemon.net> wrote:

> On Mon, Nov 26, 2012 at 10:25:35AM +0100, Thomas Petazzoni wrote:
> > On Mon, 26 Nov 2012 10:18:47 +0100, Hector Oron wrote:
> > 
> > > I got an ax3/2 device, I would not mind to test any changes? Are you
> > > aware of which changes should I apply to dtsi file to work on ax3-2
> > > device?
> > 
> > If I'm correct, the differences between AX-2 and AX3-4 is:
> > 
> >  * AX3-2 has two Ethernet interfaces, while AX3-4 has four Ethernet
> >    interfaces
> > 
> >  * AX3-4 is in standard mounted with a 2 GB additional DRAM in a
> >    SO-DIMM slot, while the AX3-2 is not. However, it is not clear if
> >    the SO-DIMM slot is present or not on the AX3-2 (could you confirm
> >    this?).
> > 
> >  * AX3-2 does not have a mini PCIe slot, while AX3-4 has one.
> > 
> > So I guess you could create a separate armada-xp-openblocks-ax3-2.dts
> > file to support this new board. Maybe at some point it will make sense
> > to have a common armada-xp-openblocks-ax3.dtsi that both board .dts
> > includes.
> 
> Adding plathome to the email list to see if they can offer any
> concrete answers.
> 
> thx,
> 
> Jason.

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board
  2012-11-28  2:45           ` Mio Watanabe
@ 2012-12-16 16:18             ` Hector Oron
  0 siblings, 0 replies; 17+ messages in thread
From: Hector Oron @ 2012-12-16 16:18 UTC (permalink / raw)
  To: linux-arm-kernel

Hello,

>> On Mon, Nov 26, 2012 at 10:25:35AM +0100, Thomas Petazzoni wrote:
>> > On Mon, 26 Nov 2012 10:18:47 +0100, Hector Oron wrote:

>> > > I got an ax3/2 device, I would not mind to test any changes? Are you
>> > > aware of which changes should I apply to dtsi file to work on ax3-2
>> > > device?

>> > If I'm correct, the differences between AX-2 and AX3-4 is:

Apologies for confusion, while the box I had referenced AX3/2, the
machine inside is a AX3/4. So, currently I am trying to test Linus'
tree which has merged your patchsets.

Best regards,
-- 
 H?ctor Or?n  -.. . -... .. .- -.   -.. . ...- . .-.. --- .--. . .-.

^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2012-12-16 16:18 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-10-23  8:19 [PATCH] arm: mvebu: support for the PlatHome OpenBlocks AX3 board Thomas Petazzoni
2012-10-23  8:42 ` Andrew Lunn
2012-10-23  8:45   ` Thomas Petazzoni
2012-10-23 11:16     ` Jason Cooper
2012-10-24  8:58 ` Gregory CLEMENT
2012-10-24 14:15   ` Thomas Petazzoni
2012-10-24 15:06 ` Andrew Lunn
2012-10-24 15:20   ` Thomas Petazzoni
2012-10-24 15:31     ` Andrew Lunn
2012-10-24 15:35       ` Thomas Petazzoni
2012-11-26  9:18     ` Hector Oron
2012-11-26  9:25       ` Thomas Petazzoni
2012-11-27 13:00         ` Jason Cooper
2012-11-28  2:45           ` Mio Watanabe
2012-12-16 16:18             ` Hector Oron
2012-10-24 19:33 ` [PATCH v2] arm: mvebu: support for the PlatHome OpenBlocks AX3-4 board Thomas Petazzoni
2012-11-05 17:48   ` Olof Johansson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).