Skip to contentSkip to conversation

Add Pantheon soc and dkb board support

PATCH Superseded Lei Wen 4 participants 26 messages Jan 10, 2011 – Jan 26, 2011

Subsystems (2)

v2 of 8 Superseded Latest is v8 →

lore
Share & tools
lore

Lei Wen

author
#0 lore raw

v2 cover Add Pantheon soc and dkb board support

This patch set add the Pantheon soc and dkb board support.

V2:
This patch seris update the seperate mv_common part as suggested.

Lei Wen (5):
mv: seperate kirkwood and armada from common setting
ARM: Add Support for Marvell Pantheon Familiy SoCs
serial: add pantheon soc support
mvmfp: add MFP configuration support for PANTHEON
Pantheon: Add Board Support for Marvell dkb board

 MAINTAINERS                                   |    4 +
 arch/arm/cpu/arm926ejs/pantheon/Makefile      |   46 ++++++
 arch/arm/cpu/arm926ejs/pantheon/cpu.c         |   78 ++++++++++
 arch/arm/cpu/arm926ejs/pantheon/dram.c        |  130 ++++++++++++++++
 arch/arm/cpu/arm926ejs/pantheon/timer.c       |  204 +++++++++++++++++++++++++
 arch/arm/include/asm/arch-armada100/config.h  |   50 ++++++
 arch/arm/include/asm/arch-kirkwood/config.h   |  145 ++++++++++++++++++
 arch/arm/include/asm/arch-pantheon/config.h   |   44 ++++++
 arch/arm/include/asm/arch-pantheon/cpu.h      |   79 ++++++++++
 arch/arm/include/asm/arch-pantheon/mfp.h      |   42 +++++
 arch/arm/include/asm/arch-pantheon/pantheon.h |   54 +++++++
 board/Marvell/dkb/Makefile                    |   51 ++++++
 board/Marvell/dkb/dkb.c                       |   53 +++++++
 boards.cfg                                    |    1 +
 drivers/gpio/mvmfp.c                          |    2 +
 drivers/serial/serial.c                       |    2 +
 include/configs/aspenite.h                    |    1 +
 include/configs/dkb.h                         |   64 ++++++++
 include/configs/mv-common.h                   |  147 +++---------------
 19 files changed, 1071 insertions(+), 126 deletions(-)
 create mode 100644 arch/arm/cpu/arm926ejs/pantheon/Makefile
 create mode 100644 arch/arm/cpu/arm926ejs/pantheon/cpu.c
 create mode 100644 arch/arm/cpu/arm926ejs/pantheon/dram.c
 create mode 100644 arch/arm/cpu/arm926ejs/pantheon/timer.c
 create mode 100644 arch/arm/include/asm/arch-armada100/config.h
 create mode 100644 arch/arm/include/asm/arch-kirkwood/config.h
 create mode 100644 arch/arm/include/asm/arch-pantheon/config.h
 create mode 100644 arch/arm/include/asm/arch-pantheon/cpu.h
 create mode 100644 arch/arm/include/asm/arch-pantheon/mfp.h
 create mode 100644 arch/arm/include/asm/arch-pantheon/pantheon.h
 create mode 100644 board/Marvell/dkb/Makefile
 create mode 100644 board/Marvell/dkb/dkb.c
 create mode 100644 include/configs/dkb.h
author
#1 lore raw

PATCH v2 1/5 mv: seperate kirkwood and armada from common setting

Since there are lots of difference between kirkwood and armada series, it is better to seperate them but still keep the most common file shared by all marvell platform in the mv-common configure file.

This patch move the kirkwood only driver definitoin in mv-common to the <soc_name>/config.h.

This patch is tested with compilation for armada100 and guruplug.

---
 arch/arm/include/asm/arch-armada100/config.h |   50 +++++++++
 arch/arm/include/asm/arch-kirkwood/config.h  |  145 +++++++++++++++++++++++++
 include/configs/aspenite.h                   |    1 +
 include/configs/mv-common.h                  |  147 ++++----------------------
 4 files changed, 217 insertions(+), 126 deletions(-)
 create mode 100644 arch/arm/include/asm/arch-armada100/config.h
 create mode 100644 arch/arm/include/asm/arch-kirkwood/config.h
arch/arm/include/asm/arch-armada100/config.h new file +50 -0
new file mode 100644
index 0000000..9995b1a
@@ -0,0 +1,50 @@
+/*
+ * (C) Copyright 2010
+ * Marvell Semiconductor <www.marvell.com>
+ * Written-by: Lei Wen <[email protected]>
+ *
+ * See file CREDITS for list of people who contributed to this
+ * project.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301 USA
+ */
+
+/*
+ * This file should be included in board config header file.
+ *
+ * It supports common definitions for Armada100 platform
+ */
+
+#ifndef _ARMD1_CONFIG_H
+#define _ARMD1_CONFIG_H
+
+#define CONFIG_ARM926EJS	1	/* Basic Architecture */
+
+#define CONFIG_SYS_TCLK		(14745600)	/* NS16550 clk config */
+#define CONFIG_SYS_HZ_CLOCK	(3250000)	/* Timer Freq. 3.25MHZ */
+#define CONFIG_MARVELL_MFP			/* Enable mvmfp driver */
+#define MV_MFPR_BASE		ARMD1_MFPR_BASE
+#define MV_UART_CONSOLE_BASE	ARMD1_UART1_BASE
+#define CONFIG_SYS_NS16550_IER	(1 << 6)	/* Bit 6 in UART_IER register
+						represents UART Unit Enable */
+/*
+ * There is no internal RAM in ARMADA100, using DRAM
+ * TBD: dcache to be used for this
+ */
+#define CONFIG_SYS_INIT_SP_ADDR		(CONFIG_SYS_TEXT_BASE - 0x00200000)
+#define CONFIG_NR_DRAM_BANKS_MAX	2
+
+#endif /* _ARMD1_CONFIG_H */
arch/arm/include/asm/arch-kirkwood/config.h new file +145 -0

145 lines not on this page · raw message

include/configs/aspenite.h +1 -0
index 706365f..48706cb 100644
@@ -53,6 +53,7 @@
  * to enable certain macros
  */
 #include "mv-common.h"
+#undef CONFIG_ARCH_MISC_INIT
 
 /*
  * Environment variables configurations
include/configs/mv-common.h +21 -126

192 lines not on this page · raw message

Signature · 1 line
1.7.0.4
author
#3 lore raw

PATCH v2 2/5 ARM: Add Support for Marvell Pantheon Familiy SoCs

In reply to Lei Wen

Pantheon Family processors are highly integrated SoCs based on Sheeva_88SV331x-v5 PJ1 cpu core. Ref:
http://www.marvell.com/products/processors/communications/marvell_pantheon_910_920_pb.pdf

SoC versions Supported:
1) PANTHEON920 (TD)
2) PANTHEON910 (TTC)

---
 arch/arm/cpu/arm926ejs/pantheon/Makefile      |   46 ++++++
 arch/arm/cpu/arm926ejs/pantheon/cpu.c         |   78 ++++++++++
 arch/arm/cpu/arm926ejs/pantheon/dram.c        |  130 ++++++++++++++++
 arch/arm/cpu/arm926ejs/pantheon/timer.c       |  204 +++++++++++++++++++++++++
 arch/arm/include/asm/arch-pantheon/config.h   |   44 ++++++
 arch/arm/include/asm/arch-pantheon/cpu.h      |   79 ++++++++++
 arch/arm/include/asm/arch-pantheon/pantheon.h |   54 +++++++
 7 files changed, 635 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/cpu/arm926ejs/pantheon/Makefile
 create mode 100644 arch/arm/cpu/arm926ejs/pantheon/cpu.c
 create mode 100644 arch/arm/cpu/arm926ejs/pantheon/dram.c
 create mode 100644 arch/arm/cpu/arm926ejs/pantheon/timer.c
 create mode 100644 arch/arm/include/asm/arch-pantheon/config.h
 create mode 100644 arch/arm/include/asm/arch-pantheon/cpu.h
 create mode 100644 arch/arm/include/asm/arch-pantheon/pantheon.h
arch/arm/cpu/arm926ejs/pantheon/Makefile new file +46 -0
new file mode 100644
index 0000000..73644c7
@@ -0,0 +1,46 @@
+#
+# (C) Copyright 2010
+# Marvell Semiconductor <www.marvell.com>
+# Written-by: Lei Wen <[email protected]>
+#
+# See file CREDITS for list of people who contributed to this
+# project.
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2 of
+# the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+# MA 02110-1301 USA
+#
+
+include $(TOPDIR)/config.mk
+
+LIB	= $(obj)lib$(SOC).o
+
+COBJS-y	= cpu.o timer.o dram.o
+
+SRCS	:= $(SOBJS:.o=.S) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS-y))
+
+all:	$(obj).depend $(LIB)
+
+$(LIB):	$(OBJS)
+	$(AR) $(ARFLAGS) $@ $(OBJS)
+
+#########################################################################
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+
+#########################################################################
arch/arm/cpu/arm926ejs/pantheon/cpu.c new file +78 -0

78 lines not on this page · raw message

arch/arm/cpu/arm926ejs/pantheon/dram.c new file +130 -0

130 lines not on this page · raw message

arch/arm/cpu/arm926ejs/pantheon/timer.c new file +204 -0

204 lines not on this page · raw message

arch/arm/include/asm/arch-pantheon/config.h new file +44 -0

44 lines not on this page · raw message

arch/arm/include/asm/arch-pantheon/cpu.h new file +79 -0

79 lines not on this page · raw message

arch/arm/include/asm/arch-pantheon/pantheon.h new file +54 -0

54 lines not on this page · raw message

Signature · 1 line
1.7.0.4
author
#8 lore raw

PATCH v2 3/5 serial: add pantheon soc support

In reply to Lei Wen
---
 drivers/serial/serial.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
drivers/serial/serial.c +2 -0
index cd3439e..4032dfd 100644
@@ -33,6 +33,8 @@
 #include <asm/arch/orion5x.h>
 #elif defined(CONFIG_ARMADA100)
 #include <asm/arch/armada100.h>
+#elif defined(CONFIG_PANTHEON)
+#include <asm/arch/pantheon.h>
 #endif
 
 #if defined (CONFIG_SERIAL_MULTI)
Signature · 1 line
1.7.0.4
author
#11 lore raw

PATCH v2 4/5 mvmfp: add MFP configuration support for PANTHEON

In reply to Lei Wen

This patch adds the support MFP support for Marvell PANTHEON SoCs

---
 arch/arm/include/asm/arch-pantheon/mfp.h |   42 ++++++++++++++++++++++++++++++
 drivers/gpio/mvmfp.c                     |    2 +
 2 files changed, 44 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/include/asm/arch-pantheon/mfp.h
arch/arm/include/asm/arch-pantheon/mfp.h new file +42 -0
new file mode 100644
index 0000000..ad1ed03
@@ -0,0 +1,42 @@
+/*
+ * Based on arch/arm/include/asm/arch-armada100/mfp.h
+ * (C) Copyright 2010
+ * Marvell Semiconductor <www.marvell.com>
+ * Written-by: Lei Wen <[email protected]>
+ *
+ * See file CREDITS for list of people who contributed to this
+ * project.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301 USA
+ */
+
+#ifndef __PANTHEON_MFP_H
+#define __PANTHEON_MFP_H
+
+/*
+ * Frequently used MFP Configuration macros for all PANTHEON family of
+SoCs
+ *
+ * offset, pull,pF, drv,dF, edge,eF ,afn,aF
+ */
+/* UART2 */
+#define MFP47_UART2_RXD		MFP_REG(0x198) | MFP_AF6 | MFP_DRIVE_MEDIUM
+#define MFP48_UART2_TXD		MFP_REG(0x19c) | MFP_AF6 | MFP_DRIVE_MEDIUM
+
+/* More macros can be defined here... */
+
+#define MFP_PIN_MAX	117
+#endif
drivers/gpio/mvmfp.c +2 -0
index 5646ed4..e7830c6 100644
@@ -28,6 +28,8 @@
 #include <asm/arch/mfp.h>
 #ifdef CONFIG_ARMADA100
 #include <asm/arch/armada100.h>
+#elif defined(CONFIG_PANTHEON)
+#include <asm/arch/pantheon.h>
 #else
 #error Unsupported SoC...
 #endif
Signature · 1 line
1.7.0.4
author
#22 lore raw

PATCH v2 5/5 Pantheon: Add Board Support for Marvell dkb board

In reply to Lei Wen

DKB is a Development Board for PANTHEON TD/TTC(pxa920/pxa910) with
* Processor upto 806Mhz
* LPDDR1/2
* x8/x16 SLC/MLC NAND
* Footprints for eMMC & MMC x8 card

With Peripherals:
* Parallel LCD I/F
* Audio codecs (88PM8607)
* MIPI CSI-2 camera
* Marvell 88W8787 802.11n/BT module
* Marvell 2G/3G RF
* Dual analog mics & speakers, headset jack, LED, ambient
* USB2.0 HS host, OTG (mini AB)
* GPIO, GPIO expander with DIP switches for easier selection
* UART serial over USB, CIR

This patch adds basic board support with DRAM and UART functionality

---
 MAINTAINERS                |    4 +++
 board/Marvell/dkb/Makefile |   51 +++++++++++++++++++++++++++++++++++
 board/Marvell/dkb/dkb.c    |   53 ++++++++++++++++++++++++++++++++++++
 boards.cfg                 |    1 +
 include/configs/dkb.h      |   64 ++++++++++++++++++++++++++++++++++++++++++++
 5 files changed, 173 insertions(+), 0 deletions(-)
 create mode 100644 board/Marvell/dkb/Makefile
 create mode 100644 board/Marvell/dkb/dkb.c
 create mode 100644 include/configs/dkb.h
MAINTAINERS +4 -0
index 96fad4b..0a37a01 100644
@@ -839,6 +839,10 @@ Prafulla Wadaskar <[email protected]>
 	rd6281a		ARM926EJS (Kirkwood SoC)
 	sheevaplug	ARM926EJS (Kirkwood SoC)
 
+Lei Wen <[email protected]>
+
+	dkb		ARM926EJS (PANTHEON 88AP920 SOC)
+
 Matthias Weisser <[email protected]>
 
 	jadecpu		ARM926EJS (MB86R01 SoC)
board/Marvell/dkb/Makefile new file +51 -0

51 lines not on this page · raw message

board/Marvell/dkb/dkb.c new file +53 -0

53 lines not on this page · raw message

boards.cfg +1 -0
index ee9a1a3..007175e 100644
@@ -100,6 +100,7 @@ imx27lite                    arm         arm926ejs   imx27lite           logicpd
 magnesium                    arm         arm926ejs   imx27lite           logicpd        mx27
 omap5912osk                  arm         arm926ejs   -                   ti             omap
 edminiv2                     arm         arm926ejs   -                   LaCie          orion5x
+dkb			     arm         arm926ejs   -                   Marvell        pantheon
 ca9x4_ct_vxp                 arm         armv7       vexpress            armltd
 mx51evk                      arm         armv7       mx51evk             freescale      mx5
 vision2                      arm         armv7       vision2             ttcontrol      mx5
include/configs/dkb.h new file +64 -0

64 lines not on this page · raw message

Signature · 1 line
1.7.0.4
#2 lore raw

PATCH v2 1/5 mv: seperate kirkwood and armada from common setting

In reply to Lei Wen
Quoted 26 lines

-----Original Message-----
From: Lei Wen [mailto:leiwen at marvell.com]
Sent: Monday, January 10, 2011 9:31 AM
To: u-boot at lists.denx.de; Prafulla Wadaskar; Yu Tang; Ashish Karkare; Prabhanjan Sarnaik; adrian . wenl @ gmail . com "
Subject: [PATCH V2 1/5] mv: seperate kirkwood and armada from common setting

Since there are lots of difference between kirkwood and armada series, it is better to seperate them but still keep the most common file shared by all marvell platform in the mv-common configure file.

This patch move the kirkwood only driver definitoin in mv-common to the <soc_name>/config.h.

This patch is tested with compilation for armada100 and guruplug.

---
 arch/arm/include/asm/arch-armada100/config.h |   50 +++++++++
 arch/arm/include/asm/arch-kirkwood/config.h  |  145
+++++++++++++++++++++++++
 include/configs/aspenite.h                   |    1 +
 include/configs/mv-common.h                  |  147 ++++---------------

...snip...

include/configs/mv-common.h line 128

Quoted 8 lines

#define CONFIG_DISPLAY_CPUINFO /* Display cpu info */
#define CONFIG_STACKSIZE 0x00100000 /* regular stack- 1M */

include/configs/mv-common.h +2 -0
@@ -199,27 +124,32 @@
 #endif
 #endif /* CONFIG_NR_DRAM_BANKS */
 
+/* ====> Include platform Common Definations */
+#include <asm/arch/config.h>

I think you should move this include in the beginning, if there is any specific arch specific definition that can be used further down in this file.

Rest ack for the rest of the patch.

Regards..
Prafulla . .

#4 lore raw

PATCH v2 2/5 ARM: Add Support for Marvell Pantheon Familiy SoCs

In reply to Lei Wen
Quoted 46 lines

-----Original Message-----
From: Lei Wen [mailto:leiwen at marvell.com]
Sent: Monday, January 10, 2011 9:31 AM
To: u-boot at lists.denx.de; Prafulla Wadaskar; Yu Tang; Ashish Karkare; Prabhanjan Sarnaik; adrian . wenl @ gmail . com "
Subject: [PATCH V2 2/5] ARM: Add Support for Marvell Pantheon Familiy SoCs

Pantheon Family processors are highly integrated SoCs based on Sheeva_88SV331x-v5 PJ1 cpu core. Ref:
http://www.marvell.com/products/processors/communications/marvell_panthe
on_910_920_pb.pdf

SoC versions Supported:
1) PANTHEON920 (TD)
2) PANTHEON910 (TTC)

---
 arch/arm/cpu/arm926ejs/pantheon/Makefile      |   46 ++++++
 arch/arm/cpu/arm926ejs/pantheon/cpu.c         |   78 ++++++++++
 arch/arm/cpu/arm926ejs/pantheon/dram.c        |  130 ++++++++++++++++
 arch/arm/cpu/arm926ejs/pantheon/timer.c       |  204
+++++++++++++++++++++++++
 arch/arm/include/asm/arch-pantheon/config.h   |   44 ++++++
 arch/arm/include/asm/arch-pantheon/cpu.h      |   79 ++++++++++
 arch/arm/include/asm/arch-pantheon/pantheon.h |   54 +++++++
 7 files changed, 635 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/cpu/arm926ejs/pantheon/Makefile
 create mode 100644 arch/arm/cpu/arm926ejs/pantheon/cpu.c
 create mode 100644 arch/arm/cpu/arm926ejs/pantheon/dram.c
 create mode 100644 arch/arm/cpu/arm926ejs/pantheon/timer.c
 create mode 100644 arch/arm/include/asm/arch-pantheon/config.h
 create mode 100644 arch/arm/include/asm/arch-pantheon/cpu.h
 create mode 100644 arch/arm/include/asm/arch-pantheon/pantheon.h
arch/arm/cpu/arm926ejs/pantheon/Makefile new file +0 -0
new file mode 100644
index 0000000..73644c7

arch/arm/cpu/arm926ejs/pantheon/Makefile line 2

Quoted 2 lines
arch/arm/cpu/arm926ejs/pantheon/Makefile new file +2 -0
@@ -0,0 +1,46 @@
+#
+# (C) Copyright 2010

2011 ??

Regards..
Prafulla . . .

#23 lore raw

PATCH v2 5/5 Pantheon: Add Board Support for Marvell dkb board

In reply to Lei Wen
Quoted 63 lines

-----Original Message-----
From: Lei Wen [mailto:leiwen at marvell.com]
Sent: Monday, January 10, 2011 9:31 AM
To: u-boot at lists.denx.de; Prafulla Wadaskar; Yu Tang; Ashish Karkare; Prabhanjan Sarnaik; adrian . wenl @ gmail . com "
Subject: [PATCH V2 5/5] Pantheon: Add Board Support for Marvell dkb board

DKB is a Development Board for PANTHEON TD/TTC(pxa920/pxa910) with
* Processor upto 806Mhz
* LPDDR1/2
* x8/x16 SLC/MLC NAND
* Footprints for eMMC & MMC x8 card

With Peripherals:
* Parallel LCD I/F
* Audio codecs (88PM8607)
* MIPI CSI-2 camera
* Marvell 88W8787 802.11n/BT module
* Marvell 2G/3G RF
* Dual analog mics & speakers, headset jack, LED, ambient
* USB2.0 HS host, OTG (mini AB)
* GPIO, GPIO expander with DIP switches for easier selection
* UART serial over USB, CIR

This patch adds basic board support with DRAM and UART functionality

---
 MAINTAINERS                |    4 +++
 board/Marvell/dkb/Makefile |   51 +++++++++++++++++++++++++++++++++++
 board/Marvell/dkb/dkb.c    |   53 ++++++++++++++++++++++++++++++++++++
 boards.cfg                 |    1 +
 include/configs/dkb.h      |   64
++++++++++++++++++++++++++++++++++++++++++++
 5 files changed, 173 insertions(+), 0 deletions(-)
 create mode 100644 board/Marvell/dkb/Makefile
 create mode 100644 board/Marvell/dkb/dkb.c
 create mode 100644 include/configs/dkb.h
MAINTAINERS +4 -0
index 96fad4b..0a37a01 100644
@@ -839,6 +839,10 @@ Prafulla Wadaskar <[email protected]>
 	rd6281a		ARM926EJS (Kirkwood SoC)
 	sheevaplug	ARM926EJS (Kirkwood SoC)
 
+Lei Wen <[email protected]>
+
+	dkb		ARM926EJS (PANTHEON 88AP920 SOC)
+
 Matthias Weisser <[email protected]>
 
 	jadecpu		ARM926EJS (MB86R01 SoC)
board/Marvell/dkb/Makefile new file +0 -0
new file mode 100644
index 0000000..8835f8e

board/Marvell/dkb/Makefile line 2

Quoted 2 lines
board/Marvell/dkb/Makefile new file +2 -0
@@ -0,0 +1,51 @@
+#
+# (C) Copyright 2010

Ditto

Regards..
Prafulla . .

#24 lore raw

v2 cover Add Pantheon soc and dkb board support

In reply to Lei Wen
Quoted 33 lines

-----Original Message-----
From: Lei Wen [mailto:leiwen at marvell.com]
Sent: Monday, January 10, 2011 9:31 AM
To: u-boot at lists.denx.de; Prafulla Wadaskar; Yu Tang; Ashish Karkare; Prabhanjan Sarnaik; adrian . wenl @ gmail . com "
Subject: [PATCH V2 0/5] Add Pantheon soc and dkb board support

This patch set add the Pantheon soc and dkb board support.

V2:
This patch seris update the seperate mv_common part as suggested.

Lei Wen (5):
mv: seperate kirkwood and armada from common setting
ARM: Add Support for Marvell Pantheon Familiy SoCs
serial: add pantheon soc support
mvmfp: add MFP configuration support for PANTHEON
Pantheon: Add Board Support for Marvell dkb board

 MAINTAINERS                                   |    4 +
 arch/arm/cpu/arm926ejs/pantheon/Makefile      |   46 ++++++
 arch/arm/cpu/arm926ejs/pantheon/cpu.c         |   78 ++++++++++
 arch/arm/cpu/arm926ejs/pantheon/dram.c        |  130 ++++++++++++++++
 arch/arm/cpu/arm926ejs/pantheon/timer.c       |  204
+++++++++++++++++++++++++
 arch/arm/include/asm/arch-armada100/config.h  |   50 ++++++
 arch/arm/include/asm/arch-kirkwood/config.h   |  145 ++++++++++++++++++
 arch/arm/include/asm/arch-pantheon/config.h   |   44 ++++++
 arch/arm/include/asm/arch-pantheon/cpu.h      |   79 ++++++++++
 arch/arm/include/asm/arch-pantheon/mfp.h      |   42 +++++
 arch/arm/include/asm/arch-pantheon/pantheon.h |   54 +++++++
Quoted 8 lines
 board/Marvell/dkb/Makefile                    |   51 ++++++
 board/Marvell/dkb/dkb.c                       |   53 +++++++
 boards.cfg                                    |    1 +
 drivers/gpio/mvmfp.c                          |    2 +
 drivers/serial/serial.c                       |    2 +
 include/configs/aspenite.h                    |    1 +
 include/configs/dkb.h                         |   64 ++++++++
 include/configs/mv-common.h                   |  147 +++-------------

One common feedback for all added files, copyright year needs to be changed.

Regards..
Prafulla . .

#25 lore raw

v2 cover Add Pantheon soc and dkb board support

Quoted 42 lines · Prafulla Wadaskar
Quoted 33 lines

-----Original Message-----
From: Lei Wen [mailto:leiwen at marvell.com]
Sent: Monday, January 10, 2011 9:31 AM
To: u-boot at lists.denx.de; Prafulla Wadaskar; Yu Tang; Ashish Karkare; Prabhanjan Sarnaik; adrian . wenl @ gmail . com "
Subject: [PATCH V2 0/5] Add Pantheon soc and dkb board support

This patch set add the Pantheon soc and dkb board support.

V2:
This patch seris update the seperate mv_common part as suggested.

Lei Wen (5):
? mv: seperate kirkwood and armada from common setting ? ARM: Add Support for Marvell Pantheon Familiy SoCs ? serial: add pantheon soc support
? mvmfp: add MFP configuration support for PANTHEON ? Pantheon: Add Board Support for Marvell dkb board

?MAINTAINERS ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? | ? ?4 +
?arch/arm/cpu/arm926ejs/pantheon/Makefile ? ? ?| ? 46 ++++++
?arch/arm/cpu/arm926ejs/pantheon/cpu.c ? ? ? ? | ? 78 ++++++++++
?arch/arm/cpu/arm926ejs/pantheon/dram.c ? ? ? ?| ?130 ++++++++++++++++
?arch/arm/cpu/arm926ejs/pantheon/timer.c ? ? ? | ?204
+++++++++++++++++++++++++
?arch/arm/include/asm/arch-armada100/config.h ?| ? 50 ++++++
?arch/arm/include/asm/arch-kirkwood/config.h ? | ?145 ++++++++++++++++++
?arch/arm/include/asm/arch-pantheon/config.h ? | ? 44 ++++++
?arch/arm/include/asm/arch-pantheon/cpu.h ? ? ?| ? 79 ++++++++++
?arch/arm/include/asm/arch-pantheon/mfp.h ? ? ?| ? 42 +++++
?arch/arm/include/asm/arch-pantheon/pantheon.h | ? 54 +++++++
Quoted 8 lines
?board/Marvell/dkb/Makefile ? ? ? ? ? ? ? ? ? ?| ? 51 ++++++
?board/Marvell/dkb/dkb.c ? ? ? ? ? ? ? ? ? ? ? | ? 53 +++++++
?boards.cfg ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?| ? ?1 +
?drivers/gpio/mvmfp.c ? ? ? ? ? ? ? ? ? ? ? ? ?| ? ?2 +
?drivers/serial/serial.c ? ? ? ? ? ? ? ? ? ? ? | ? ?2 +
?include/configs/aspenite.h ? ? ? ? ? ? ? ? ? ?| ? ?1 +
?include/configs/dkb.h ? ? ? ? ? ? ? ? ? ? ? ? | ? 64 ++++++++
?include/configs/mv-common.h ? ? ? ? ? ? ? ? ? | ?147 +++-------------
Quoted 2 lines

One common feedback for all added files, copyright year needs to be changed.

Yep, that is my mistake, I would update the patch set for it...

Best regards,
Lei

#9 lore raw

PATCH v2 3/5 serial: add pantheon soc support

In reply to Lei Wen

Dear Prafulla,

Quoted 10 lines · In message <[email protected]> Lei Wen wrote:
---
 drivers/serial/serial.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
drivers/serial/serial.c +0 -0
index cd3439e..4032dfd 100644

drivers/serial/serial.c line 40

Quoted 8 lines
drivers/serial/serial.c +2 -0
@@ -33,6 +33,8 @@
 #include <asm/arch/orion5x.h>
 #elif defined(CONFIG_ARMADA100)
 #include <asm/arch/armada100.h>
+#elif defined(CONFIG_PANTHEON)
+#include <asm/arch/pantheon.h>
 #endif
 
 #if defined (CONFIG_SERIAL_MULTI)

Please pull with rest of patch series through your repository. Thanks.

Best regards,

Wolfgang Denk

Signature · 6 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
One essential to success is that you desire be an all-obsessing  one,
your thoughts and aims be co-ordinated, and your energy be concentra-
ted and applied without letup.
#5 lore raw

PATCH v2 2/5 ARM: Add Support for Marvell Pantheon Familiy SoCs

In reply to Lei Wen

Dear Lei Wen,

Quoted 10 lines · In message <[email protected]> you wrote:

Pantheon Family processors are highly integrated SoCs based on Sheeva_88SV331x-v5 PJ1 cpu core. Ref:
http://www.marvell.com/products/processors/communications/marvell_pantheon_910_920_pb.pdf

SoC versions Supported:
1) PANTHEON920 (TD)
2) PANTHEON910 (TTC)

...

Quoted 2 lines
(quoted diff) +2 -0
+int dram_init(void)
+{

...

arch/arm/cpu/arm926ejs/pantheon/dram.c line 115

Quoted 5 lines
arch/arm/cpu/arm926ejs/pantheon/dram.c new file +5 -0
+	for (; i < CONFIG_NR_DRAM_BANKS; i++) {
+		/* If above loop terminated prematurely, we need to set
+		 * remaining banks' start address & size as 0. Otherwise other
+		 * u-boot functions and Linux kernel gets wrong values which
+		 * could result in crash */

Incorrect multiline comment style.

Quoted 4 lines

+/* For preventing risk of instability in reading counter value,
+ * first set read request to register cvwr and then read same
+ * register after it captures counter value.
+ */

Ditto. Please fix globally.

arch/arm/cpu/arm926ejs/pantheon/timer.c line 75

Quoted 2 lines
arch/arm/cpu/arm926ejs/pantheon/timer.c new file +2 -0
+	writel(COUNT_RD_REQ, &panthtimers->cvwr);
+	while (loop--);

Please write:

	while (loop--)
		;

But then - are you sure the compiler does not optimize this out? You probably want to use __udelay() instead.

...

Quoted 3 lines
arch/arm/include/asm/arch-pantheon/config.h new file +0 -0
@@ -0,0 +1,44 @@

...

arch/arm/include/asm/arch-pantheon/config.h line 42

Quoted 6 lines
arch/arm/include/asm/arch-pantheon/config.h new file +6 -0
+/*
+ * There is no internal RAM in ARMADA100, using DRAM
+ * TBD: dcache to be used for this
+ */
+#define CONFIG_SYS_INIT_SP_ADDR		(CONFIG_SYS_TEXT_BASE - 0x00200000)
+#define CONFIG_NR_DRAM_BANKS_MAX	2

This looks like board specific code that should not be here.

...

arch/arm/include/asm/arch-pantheon/config.h

Quoted 9 lines
arch/arm/include/asm/arch-pantheon/config.h new file +9 -0
+struct panthmpmu_registers {
+	u8 pad0[0x0024];
+	u32 ccgr;	/*0x0024*/
+	u8 pad1[0x0200 - 0x024 - 4];
+	u32 wdtpcr;	/*0x0200*/
+	u8 pad2[0x1020 - 0x200 - 4];
+	u32 aprr;	/*0x1020*/
+	u32 acgr;	/*0x1024*/
+};

Please use TAB for vertical alignment of variable names. Please fix globally.

Best regards,

Wolfgang Denk

Signature · 5 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
You see but you do not observe.
Sir Arthur Conan Doyle, in "The Memoirs of Sherlock Holmes"
#12 lore raw

PATCH v2 4/5 mvmfp: add MFP configuration support for PANTHEON

In reply to Lei Wen

Dear Lei Wen,

Quoted 1 line · In message <[email protected]> you wrote:

This patch adds the support MFP support for Marvell PANTHEON SoCs

"the support MFP support" ??

Please fix. Also, please explain what MFP is. It may be obvious to you, it ain't so for me.

arch/arm/include/asm/arch-pantheon/mfp.h line 31

Quoted 3 lines
arch/arm/include/asm/arch-pantheon/mfp.h new file +3 -0
+/*
+ * Frequently used MFP Configuration macros for all PANTHEON family of
+SoCs

Line wrapped - please fix.

Best regards,

Wolfgang Denk

Signature · 6 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
"Probably the best operating system in the world  is  the  [operating
system] made for the PDP-11 by Bell Laboratories."
                                           - Ted Nelson, October 1977
#13 lore raw

PATCH v2 4/5 mvmfp: add MFP configuration support for PANTHEON

Hi Wolfgang,

Quoted 7 lines · Wolfgang Denk

Dear Lei Wen,

Quoted 1 line · In message <[email protected]> you wrote:

This patch adds the support MFP support for Marvell PANTHEON SoCs

"the support MFP support" ??

Quoted 10 lines

Please fix. Also, please explain what MFP is. It may be obvious to you, it ain't so for me.

arch/arm/include/asm/arch-pantheon/mfp.h line 31

Quoted 3 lines
arch/arm/include/asm/arch-pantheon/mfp.h new file +3 -0
+/*
+ * Frequently used MFP Configuration macros for all PANTHEON family of
+SoCs

Line wrapped - please fix.

This already fixed in the v6 patch, maybe you didn't notice this...
http://patchwork.ozlabs.org/patch/80307/

Best regards,
Lei

#6 lore raw

PATCH v2 2/5 ARM: Add Support for Marvell Pantheon Familiy SoCs

In reply to Wolfgang Denk

Hi Wolfgang,

Quoted 17 lines · Wolfgang Denk

Dear Lei Wen,

Quoted 10 lines · In message <[email protected]> you wrote:

Pantheon Family processors are highly integrated SoCs based on Sheeva_88SV331x-v5 PJ1 cpu core. Ref:
http://www.marvell.com/products/processors/communications/marvell_pantheon_910_920_pb.pdf

SoC versions Supported:
1) PANTHEON920 ? ? ? ? ?(TD)
2) PANTHEON910 ? ? ? ? ?(TTC)

...

Quoted 2 lines
(quoted diff) +2 -0
+int dram_init(void)
+{

...

Quoted 8 lines
Quoted 5 lines

+ ? ? for (; i < CONFIG_NR_DRAM_BANKS; i++) {
+ ? ? ? ? ? ? /* If above loop terminated prematurely, we need to set
+ ? ? ? ? ? ? ?* remaining banks' start address & size as 0. Otherwise other
+ ? ? ? ? ? ? ?* u-boot functions and Linux kernel gets wrong values which
+ ? ? ? ? ? ? ?* could result in crash */

Incorrect multiline comment style.

This already fix in the v6 patch...
http://patchwork.ozlabs.org/patch/80305/

Quoted 7 lines
Quoted 4 lines

+/* For preventing risk of instability in reading counter value,
+ * first set read request to register cvwr and then read same
+ * register after it captures counter value.
+ */

Ditto. ?Please fix globally.

Quoted 7 lines
Quoted 2 lines

+ ? ? writel(COUNT_RD_REQ, &panthtimers->cvwr);
+ ? ? while (loop--);

Please write:

? ? ? ?while (loop--)
? ? ? ? ? ? ? ?;

Fixed...

Quoted 3 lines

But then - are you sure the compiler does not optimize this out? ?You probably want to use __udelay() instead.

#10 lore raw

PATCH v2 3/5 serial: add pantheon soc support

In reply to Wolfgang Denk
Quoted 31 lines

-----Original Message-----
From: Wolfgang Denk [mailto:wd at denx.de]
Sent: Tuesday, January 25, 2011 1:25 PM
To: Prafulla Wadaskar
Cc: u-boot at lists.denx.de; Lei Wen; Yu Tang; Ashish Karkare; Prabhanjan Sarnaik; adrian . wenl @ gmail . com "
Subject: Re: [U-Boot] [PATCH V2 3/5] serial: add pantheon soc support

Dear Prafulla,

In message <[email protected]> Lei Wen

Quoted 17 lines · wrote:
---
 drivers/serial/serial.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
drivers/serial/serial.c +2 -0
index cd3439e..4032dfd 100644
@@ -33,6 +33,8 @@
 #include <asm/arch/orion5x.h>
 #elif defined(CONFIG_ARMADA100)
 #include <asm/arch/armada100.h>
+#elif defined(CONFIG_PANTHEON)
+#include <asm/arch/pantheon.h>
 #endif
 
Quoted 6 lines

drivers/serial/serial.c line 40

Quoted 1 line
drivers/serial/serial.c +0 -0
 #if defined (CONFIG_SERIAL_MULTI)

Please pull with rest of patch series through your repository. Thanks.

Dear Wolfgang,
This is a patch series, need to be pulled all together. I will do it with v6, if there is no further review feedback for v6 patch series.

Regards..
Prafulla . .

#14 lore raw

PATCH v2 4/5 mvmfp: add MFP configuration support for PANTHEON

In reply to Lei Wen

Dear Lei Wen,

Quoted 15 lines · In message <[email protected]> you…
Quoted 5 lines
Quoted 2 lines

This patch adds the support MFP support for Marvell PANTHEON SoCs

"the support MFP support" ??

Quoted 10 lines

Please fix. Also, please explain what MFP is. It may be obvious to you, it ain't so for me.

arch/arm/include/asm/arch-pantheon/mfp.h line 31

Quoted 3 lines
arch/arm/include/asm/arch-pantheon/mfp.h new file +3 -0
+/*
+ * Frequently used MFP Configuration macros for all PANTHEON family of
+SoCs

Line wrapped - please fix.

Quoted 2 lines

This already fixed in the v6 patch, maybe you didn't notice this...
http://patchwork.ozlabs.org/patch/80307/

Only the line wrap was fixed.

The other 2 remarks still apply.

Best regards,

Wolfgang Denk

Signature · 5 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
I'm a programmer: I don't buy software, I write it.
                                                  -- Tom Christiansen
#18 lore raw

PATCH v2 4/5 mvmfp: add MFP configuration support for PANTHEON

In reply to Lei Wen

Dear Lei Wen,

Quoted 2 lines · In message <[email protected]> you…

This already fixed in the v6 patch, maybe you didn't notice this...

Yes, I missed this v6 series of patches, because it seems you broke the mail thread when sending it.

Please see
http://www.denx.de/wiki/view/U-Boot/Patches#Sending_updated_patch_versions
bullet # 3.

Best regards,

Wolfgang Denk

Signature · 5 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Q: How do you spell "onomatopoeia"?
A: The way it sounds.
#15 lore raw

PATCH v2 4/5 mvmfp: add MFP configuration support for PANTHEON

In reply to Wolfgang Denk

Hi Wolfgang,

Quoted 7 lines · Wolfgang Denk

Dear Lei Wen,

Quoted 4 lines · In message <[email protected]> you…
Quoted 4 lines
Quoted 2 lines

This patch adds the support MFP support for Marvell PANTHEON SoCs

"the support MFP support" ??

Sorry for the typo...

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

Please fix. Also, please explain what MFP is. It may be obvious to you, it ain't so for me.

MFP is stand for multiply function pin setting, which servers for setting a pin of cpu to server for different
functions on different design boards to better suit for its design.

Best regards,
Lei

#7 lore raw

PATCH v2 2/5 ARM: Add Support for Marvell Pantheon Familiy SoCs

In reply to Lei Wen

Dear Lei Wen,

Quoted 8 lines · In message <[email protected]> you…
Quoted 7 lines
Quoted 2 lines

+ while (loop--);

Please write:

           while (loop--)
                       ;
Quoted 6 lines

Fixed...

Quoted 3 lines

But then - are you sure the compiler does not optimize this out? You
probably want to use __udelay() instead.

From the practice, we think this loop is enough to make timer stablize...

There is nothing in this code to prevent the cmpiler from optimizing this out.

You can as well delete these lines then.

If you need a delay, then you must do better.

Quoted 1 line

Involve the __udelay() may not suitable for the timer functions...

Depends...

Best regards,

Wolfgang Denk

Signature · 5 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
"The pathology is to want control, not that you ever get it,  because
of course you never do."                            - Gregory Bateson
#19 lore raw

PATCH v2 4/5 mvmfp: add MFP configuration support for PANTHEON

In reply to Wolfgang Denk

Hi Wolfgang,

Quoted 4 lines · Wolfgang Denk

Dear Lei Wen,

Quoted 1 line · In message <[email protected]> you…
Quoted 9 lines
Quoted 1 line

This already fixed in the v6 patch, maybe you didn't notice this...

Yes, I missed this v6 series of patches, because it seems you broke the mail thread when sending it.

Please see
http://www.denx.de/wiki/view/U-Boot/Patches#Sending_updated_patch_versions
bullet # 3.

I have a question for this rule...
When I use the git-send-email to send the whole patch set, it only ask me to input only one reference message id.
Then how this reference message id get? The previous cover letter message id? Or just send the new patch set
one patch by one patch with each previous message id?

Best regards,
Lei

#16 lore raw

PATCH v2 4/5 mvmfp: add MFP configuration support for PANTHEON

In reply to Lei Wen

Dear Lei Wen,

Quoted 7 lines · In message <[email protected]> you…
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

Please fix. Also, please explain what MFP is. It may be obvious to you, it ain't so for me.

MFP is stand for multiply function pin setting, which servers for setting a pin of cpu to server for different
functions on different design boards to better suit for its design.

multiply or multiple?

Maybe you can write something like "Add support for multiple function pin (MFP) for Marvell PANTHEON SoCs" in your commit message.

Otherwise people might wonder what Multi Function Peripherals or Multi Function Printers have to do with that.

Best regards,

Wolfgang Denk

Signature · 6 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
If I don't document something, it's usually either for a good reason,
or a bad reason.  In this case it's a good reason.  :-)
                 - Larry Wall in <[email protected]>
#20 lore raw

PATCH v2 4/5 mvmfp: add MFP configuration support for PANTHEON

In reply to Lei Wen

Dear Lei Wen,

Quoted 6 lines · In message <[email protected]> you…

I have a question for this rule...
When I use the git-send-email to send the whole patch set, it only ask me to input only one reference message id.
Then how this reference message id get? The previous cover letter message id? ...

Yes, exactly.

Quoted 1 line

one patch by one patch with each previous message id?

No.

Thanks.

Best regards,

Wolfgang Denk

Signature · 4 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
8 Catfish                                               = 1 Octo-puss
#17 lore raw

PATCH v2 4/5 mvmfp: add MFP configuration support for PANTHEON

In reply to Wolfgang Denk

Hi Wolfgang,

Quoted 4 lines · Wolfgang Denk

Dear Lei Wen,

Quoted 1 line · In message <[email protected]> you…
Quoted 8 lines
Quoted 6 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

Please fix. Also, please explain what MFP is. It may be obvious to you, it ain't so for me.

MFP is stand for multiply function pin setting, which servers for setting a pin of cpu to server for different
functions on different design boards to better suit for its design.

multiply or multiple?

Sorry for my poor English. It is multiple.

Quoted 7 lines

Maybe you can write something like "Add support for multiple function pin (MFP) for Marvell PANTHEON SoCs" in your commit message.

Otherwise people might wonder what Multi Function Peripherals or Multi Function Printers have to do with that.

Agree. Fix it in next patch set...

Best regards,
Lei

#21 lore raw

PATCH v2 4/5 mvmfp: add MFP configuration support for PANTHEON

In reply to Wolfgang Denk
Quoted 11 lines · Wolfgang Denk

Dear Lei Wen,

Quoted 6 lines · In message <[email protected]> you…

I have a question for this rule...
When I use the git-send-email to send the whole patch set, it only ask me to input only one reference message id.
Then how this reference message id get? The previous cover letter message id? ...

Yes, exactly.

Got it...

Best regards,
Lei