Skip to contentSkip to conversation

Marvell MV88F6281GTW_GE Board support

PATCH Superseded Prafulla Wadaskar 4 participants 22 messages May 4, 2009 – May 25, 2009 Kbuild

v6 of 13 Superseded Latest is v13 →

lore
Share & tools
lore
#0 lore raw

PATCH v6 1/1 Marvell MV88F6281GTW_GE Board support

From: prafulla_wadaskar <[email protected]>

This is Marvell's 88F6281_A0 based custom board developed for wireless access point product

This patch is tested for-
1. Boot from DRAM/SPI flash/NFS
2. File transfer using tftp and loadb
3. SPI flash read/write/erase
4. Booting Linux kernel and RFS from SPI flash

---
Change log
v2: updated as per first review comments
debug_prints updated to debug

v3: updaed as per review comments for v2
added mv88f6281gtw_ge.h file
removed BITxx macros

v4: updated as per review comments for v3 arch_misc_init support is added and used from kirkwood

v5: updated as per review comments for v4 CONFIG_MACH_MV88F6281GTW_GE added
more comments added and
serial configuration removed from mv88f6281gtw_ge.c

V6: clean switch configuration using netdev.h

 MAKEALL                                         |    1 +
 Makefile                                        |    3 +
 board/Marvell/mv88f6281gtw_ge/Makefile          |   51 +++++++
 board/Marvell/mv88f6281gtw_ge/config.mk         |   25 +++
 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c |   87 +++++++++++
 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h |   51 +++++++
 board/Marvell/mv88f6281gtw_ge/u-boot.lds        |   53 +++++++
 include/configs/mv88f6281gtw_ge.h               |  180 +++++++++++++++++++++++
 8 files changed, 451 insertions(+), 0 deletions(-)
 create mode 100644 board/Marvell/mv88f6281gtw_ge/Makefile
 create mode 100644 board/Marvell/mv88f6281gtw_ge/config.mk
 create mode 100644 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c
 create mode 100644 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h
 create mode 100644 board/Marvell/mv88f6281gtw_ge/u-boot.lds
 create mode 100644 include/configs/mv88f6281gtw_ge.h
MAKEALL +1 -0
index f13c81a..a7545c9 100755
@@ -504,6 +504,7 @@ LIST_ARM9="			\
 	cp946es			\
 	cp966			\
 	lpd7a400		\
+	mv88f6281gtw_ge		\
 	mx1ads			\
 	mx1fs2			\
 	netstar			\
Makefile +3 -0
index 1b43832..fdc78bf 100644
@@ -2795,6 +2795,9 @@ lpd7a400_config \
 lpd7a404_config:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm lh7a40x lpd7a40x
 
+mv88f6281gtw_ge_config: unconfig
+	@$(MKCONFIG) $(@:_config=) arm arm926ejs $(@:_config=) Marvell kirkwood
+
 mx1ads_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t mx1ads NULL imx
 
board/Marvell/mv88f6281gtw_ge/Makefile new file +51 -0

51 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/config.mk new file +25 -0
new file mode 100644
index 0000000..fb29a1b
@@ -0,0 +1,25 @@
+#
+# (C) Copyright 2009
+# Marvell Semiconductor <www.marvell.com>
+# Prafulla Wadaskar <[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
+#
+
+TEXT_BASE = 0x00600000
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +87 -0

87 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h new file +51 -0

51 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/u-boot.lds new file +53 -0

53 lines not on this page · raw message

include/configs/mv88f6281gtw_ge.h new file +180 -0

180 lines not on this page · raw message

Signature · 1 line
1.5.3.4
#1 lore raw

PATCH v6 1/1 Marvell MV88F6281GTW_GE Board support

Quoted 23 lines
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h new file +17 -0
+/*
+ * Default values for MPP registers
+ *
+ * There are maximum 64 Multi-Pourpose Pins on Kirkwood
+ * Each MPP functionality can be configuration by a 4bit value
+ * of MPP control reg, the value and associated functionality is SoC
+ * varient dependent
+ */
+#define MV88F6281GTW_GE_MPP0_7		0x01112222
+#define MV88F6281GTW_GE_MPP8_15		0x11103311
+#define MV88F6281GTW_GE_MPP16_23	0x00001111
+#define MV88F6281GTW_GE_MPP24_31	0x22222222
+#define MV88F6281GTW_GE_MPP32_39	0x40440222
+#define MV88F6281GTW_GE_MPP40_47	0x00004444
+#define MV88F6281GTW_GE_MPP48_55	0x00000000
+
+#endif /* __MV88F6281GTW_GE_H */
board/Marvell/mv88f6281gtw_ge/u-boot.lds new file +0 -0
new file mode 100644
index 0000000..9695f3f

board/Marvell/mv88f6281gtw_ge/u-boot.lds line 4

Quoted 4 lines
board/Marvell/mv88f6281gtw_ge/u-boot.lds new file +4 -0
@@ -0,0 +1,53 @@
+/*
+ * (C) Copyright 2009
+ * Marvell Semiconductor <www.marvell.com>
+ * Prafulla Wadaskar <[email protected]>

it's just a copy of other lds please do not add the Marvell Copyright as it's really the same as a lot of arm9 please move to cpu/arm926ejs/kirwood at least

I will clean the other lds myself later

You do not add yourselft as Maintainer of the board I guess you miss it

otherwise it's ok

Best Regards,
J.

#2 lore raw

PATCH v6 1/1 Marvell MV88F6281GTW_GE Board support

Quoted 34 lines

-----Original Message-----
From: Jean-Christophe PLAGNIOL-VILLARD [mailto:plagnioj at jcrosoft.com]
Sent: Tuesday, May 05, 2009 3:48 AM
To: Prafulla Wadaskar
Cc: u-boot at lists.denx.de; Ashish Karkare; Prabhanjan Sarnaik; Ronen Shitrit
Subject: Re: [U-Boot] [PATCH v6] Marvell MV88F6281GTW_GE Board support

Quoted 6 lines

+/*
+ * Default values for MPP registers
+ *
+ * There are maximum 64 Multi-Pourpose Pins on Kirkwood
+ * Each MPP functionality can be configuration by a 4bit value
+ * of MPP control reg, the value and associated

functionality is SoC

Quoted 17 lines

+ * varient dependent
+ */

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h new file +9 -0
+#define MV88F6281GTW_GE_MPP0_7		0x01112222
+#define MV88F6281GTW_GE_MPP8_15		0x11103311
+#define MV88F6281GTW_GE_MPP16_23	0x00001111
+#define MV88F6281GTW_GE_MPP24_31	0x22222222
+#define MV88F6281GTW_GE_MPP32_39	0x40440222
+#define MV88F6281GTW_GE_MPP40_47	0x00004444
+#define MV88F6281GTW_GE_MPP48_55	0x00000000
+
+#endif /* __MV88F6281GTW_GE_H */
board/Marvell/mv88f6281gtw_ge/u-boot.lds new file +0 -0
new file mode 100644
index 0000000..9695f3f
Quoted 8 lines

board/Marvell/mv88f6281gtw_ge/u-boot.lds line 4

Quoted 5 lines
board/Marvell/mv88f6281gtw_ge/u-boot.lds new file +4 -0
@@ -0,0 +1,53 @@
+/*
+ * (C) Copyright 2009
+ * Marvell Semiconductor <www.marvell.com>
+ * Prafulla Wadaskar <[email protected]>

it's just a copy of other lds please do not add the Marvell Copyright as it's really the same as a lot of arm9 please move to cpu/arm926ejs/kirwood at least

Okay, I will do it

Quoted 5 lines

I will clean the other lds myself later

You do not add yourselft as Maintainer of the board I guess you miss it

I was unaware, I will do it, any reference will help otherwise I will find it :-)

Thanks and regards..
Prafulla . .

Quoted 6 lines

otherwise it's ok

Best Regards,
J.

#3 lore raw

PATCH v7 1/1 Marvell MV88F6281GTW_GE Board support

From: prafulla_wadaskar <[email protected]>

This is Marvell's 88F6281_A0 based custom board developed for wireless access point product

This patch is tested for-
1. Boot from DRAM/SPI flash/NFS
2. File transfer using tftp and loadb
3. SPI flash read/write/erase
4. Booting Linux kernel and RFS from SPI flash

---
Change log
v2: updated as per first review comments
debug_prints updated to debug

v3: updaed as per review comments for v2
added mv88f6281gtw_ge.h file
removed BITxx macros

v4: updated as per review comments for v3 arch_misc_init support is added and used from kirkwood

v5: updated as per review comments for v4 CONFIG_MACH_MV88F6281GTW_GE added
more comments added and
serial configuration removed from mv88f6281gtw_ge.c

V6: clean switch configuration using netdev.h

v7: Marvell copyright removed from u-boot.lds
Maintainer added for this board

 MAKEALL                                         |    1 +
 Makefile                                        |    3 +
 board/Marvell/mv88f6281gtw_ge/Makefile          |   51 +++++++
 board/Marvell/mv88f6281gtw_ge/config.mk         |   25 +++
 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c |   89 +++++++++++
 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h |   51 +++++++
 board/Marvell/mv88f6281gtw_ge/u-boot.lds        |   51 +++++++
 include/configs/mv88f6281gtw_ge.h               |  180 +++++++++++++++++++++++
 8 files changed, 451 insertions(+), 0 deletions(-)
 create mode 100644 board/Marvell/mv88f6281gtw_ge/Makefile
 create mode 100644 board/Marvell/mv88f6281gtw_ge/config.mk
 create mode 100644 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c
 create mode 100644 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h
 create mode 100644 board/Marvell/mv88f6281gtw_ge/u-boot.lds
 create mode 100644 include/configs/mv88f6281gtw_ge.h
MAKEALL +1 -0
index f13c81a..a7545c9 100755
@@ -504,6 +504,7 @@ LIST_ARM9="			\
 	cp946es			\
 	cp966			\
 	lpd7a400		\
+	mv88f6281gtw_ge		\
 	mx1ads			\
 	mx1fs2			\
 	netstar			\
Makefile +3 -0
index 137c88f..5ff750c 100644
@@ -2794,6 +2794,9 @@ lpd7a400_config \
 lpd7a404_config:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm lh7a40x lpd7a40x
 
+mv88f6281gtw_ge_config: unconfig
+	@$(MKCONFIG) $(@:_config=) arm arm926ejs $(@:_config=) Marvell kirkwood
+
 mx1ads_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t mx1ads NULL imx
 
board/Marvell/mv88f6281gtw_ge/Makefile new file +51 -0

51 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/config.mk new file +25 -0
new file mode 100644
index 0000000..fb29a1b
@@ -0,0 +1,25 @@
+#
+# (C) Copyright 2009
+# Marvell Semiconductor <www.marvell.com>
+# Prafulla Wadaskar <[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
+#
+
+TEXT_BASE = 0x00600000
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +89 -0

89 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h new file +51 -0

51 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/u-boot.lds new file +51 -0

51 lines not on this page · raw message

include/configs/mv88f6281gtw_ge.h new file +180 -0

180 lines not on this page · raw message

Signature · 1 line
1.5.3.3
#4 lore raw

PATCH v8 1/1 Marvell MV88F6281GTW_GE Board support

From: prafulla_wadaskar <[email protected]>

This is Marvell's 88F6281_A0 based custom board developed for wireless access point product

This patch is tested for-
1. Boot from DRAM/SPI flash/NFS
2. File transfer using tftp and loadb
3. SPI flash read/write/erase
4. Booting Linux kernel and RFS from SPI flash

---
Change log
v2: updated as per first review comments
debug_prints updated to debug

v3: updaed as per review comments for v2
added mv88f6281gtw_ge.h file
removed BITxx macros

v4: updated as per review comments for v3 arch_misc_init support is added and used from kirkwood

v5: updated as per review comments for v4 CONFIG_MACH_MV88F6281GTW_GE added
more comments added and
serial configuration removed from mv88f6281gtw_ge.c

V6: clean switch configuration using netdev.h

v7: Marvell copyright removed from u-boot.lds
Maintainer added for this board

v8: u-boot.lds removed
finetuned for cosmetic and switch related changes

 MAKEALL                                         |    1 +
 Makefile                                        |    3 +
 board/Marvell/mv88f6281gtw_ge/Makefile          |   51 +++++++
 board/Marvell/mv88f6281gtw_ge/config.mk         |   25 +++
 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c |   91 ++++++++++++
 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h |   51 +++++++
 include/configs/mv88f6281gtw_ge.h               |  180 +++++++++++++++++++++++
 7 files changed, 402 insertions(+), 0 deletions(-)
 create mode 100644 board/Marvell/mv88f6281gtw_ge/Makefile
 create mode 100644 board/Marvell/mv88f6281gtw_ge/config.mk
 create mode 100644 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c
 create mode 100644 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h
 create mode 100644 include/configs/mv88f6281gtw_ge.h
MAKEALL +1 -0
index 57dd425..431187a 100755
@@ -505,6 +505,7 @@ LIST_ARM9="			\
 	cp946es			\
 	cp966			\
 	lpd7a400		\
+	mv88f6281gtw_ge		\
 	mx1ads			\
 	mx1fs2			\
 	netstar			\
Makefile +3 -0
index 24e6410..60ca711 100644
@@ -2794,6 +2794,9 @@ lpd7a400_config \
 lpd7a404_config:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm lh7a40x lpd7a40x
 
+mv88f6281gtw_ge_config: unconfig
+	@$(MKCONFIG) $(@:_config=) arm arm926ejs $(@:_config=) Marvell kirkwood
+
 mx1ads_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t mx1ads NULL imx
 
board/Marvell/mv88f6281gtw_ge/Makefile new file +51 -0

51 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/config.mk new file +25 -0
new file mode 100644
index 0000000..fb29a1b
@@ -0,0 +1,25 @@
+#
+# (C) Copyright 2009
+# Marvell Semiconductor <www.marvell.com>
+# Prafulla Wadaskar <[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
+#
+
+TEXT_BASE = 0x00600000
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +91 -0

91 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h new file +51 -0

51 lines not on this page · raw message

include/configs/mv88f6281gtw_ge.h new file +180 -0

180 lines not on this page · raw message

Signature · 1 line
1.5.3.3
#5 lore raw

PATCH v8 1/1 Marvell MV88F6281GTW_GE Board support

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h line 49

Quoted 11 lines

+ * Each MPP functionality can be configuration by a 4bit value
+ * of MPP control reg, the value and associated functionality is SoC
+ * varient dependent
+ */

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h new file +7 -0
+#define MV88F6281GTW_GE_MPP0_7		0x01112222
+#define MV88F6281GTW_GE_MPP8_15		0x11103311
+#define MV88F6281GTW_GE_MPP16_23	0x00001111
+#define MV88F6281GTW_GE_MPP24_31	0x22222222
+#define MV88F6281GTW_GE_MPP32_39	0x40440222
+#define MV88F6281GTW_GE_MPP40_47	0x00004444
+#define MV88F6281GTW_GE_MPP48_55	0x00000000

could you use a more details macros
and I think we can use a device init framework
to simply it

Quoted 43 lines
(quoted diff) +2 -0
+
+#endif /* __MV88F6281GTW_GE_H */
include/configs/mv88f6281gtw_ge.h new file +35 -0
new file mode 100644
index 0000000..6ec59f7
@@ -0,0 +1,180 @@
+/*
+ * (C) Copyright 2009
+ * Marvell Semiconductor <www.marvell.com>
+ * Prafulla Wadaskar <[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 _CONFIG_MV88F6281GTW_GE_H
+#define _CONFIG_MV88F6281GTW_GE_H
+
+/*
+ * Version number information
+ */
+#define CONFIG_IDENT_STRING	"\nMarvell-MV88F6281GTW_GE-A0"
+
+/*
+ * High Level Configuration Options (easy to change)
+ */

include/configs/mv88f6281gtw_ge.h line 45

Quoted 10 lines
include/configs/mv88f6281gtw_ge.h new file +10 -0
+#define CONFIG_MARVELL		1
+#define CONFIG_ARM926EJS	1	/* Basic Architecture */
+#define CONFIG_FEROCEON_88FR131	1	/* CPU Core subversion */
+#define CONFIG_KIRKWOOD		1	/* SOC Family Name */
+#define CONFIG_KW88F6281	1	/* SOC Name */
+#define CONFIG_MACH_MV88F6281GTW_GE	/* Machine type */
+
+#define CONFIG_MD5	/* get_random_hex on krikwood needs MD5 support */
+#define CONFIG_ARCH_LOWLEVEL_INIT	/* enable arch_lowlevel_init */
+#define CONFIG_SKIP_LOWLEVEL_INIT	/* disable board lowlevel_init */

NACK
If you so skip the lowlevel init you will skip *ALL* lowlevel_init arch include

include/configs/mv88f6281gtw_ge.h line 49

Quoted 4 lines
include/configs/mv88f6281gtw_ge.h new file +4 -0
+#define CONFIG_KIRKWOOD_EGIGA_INIT	/* Enable GbePort0/1 for kernel */
+#define CONFIG_KIRKWOOD_PCIE_INIT	/* Enable PCIE Port0 for kernel */
+#define CONFIG_KIRKWOOD_RGMII_PAD_1V8	/* Set RGMII Pad voltage to 1.8V */
+

Best Regards,
J.

#6 lore raw

PATCH v9 1/1 Marvell MV88F6281GTW_GE Board support

From: prafulla_wadaskar <[email protected]>

This is Marvell's 88F6281_A0 based custom board developed for wireless access point product

This patch is tested for-
1. Boot from DRAM/SPI flash/NFS
2. File transfer using tftp and loadb
3. SPI flash read/write/erase
4. Booting Linux kernel and RFS from SPI flash

---
Change log
v2: updated as per first review comments
debug_prints updated to debug

v3: updaed as per review comments for v2
added mv88f6281gtw_ge.h file
removed BITxx macros

v4: updated as per review comments for v3 arch_misc_init support is added and used from kirkwood

v5: updated as per review comments for v4 CONFIG_MACH_MV88F6281GTW_GE added
more comments added and
serial configuration removed from mv88f6281gtw_ge.c

V6: clean switch configuration using netdev.h

v7: Marvell copyright removed from u-boot.lds
Maintainer added for this board

v8: u-boot.lds removed
finetuned for cosmetic and switch related changes

v9: new mpp configuration used
CONFIG_ARCH_LOWLEVEL_INIT defination removed

 MAKEALL                                         |    1 +
 Makefile                                        |    3 +
 board/Marvell/mv88f6281gtw_ge/Makefile          |   51 ++++++
 board/Marvell/mv88f6281gtw_ge/config.mk         |   25 +++
 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c |  141 +++++++++++++++++
 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h |   36 +++++
 include/configs/mv88f6281gtw_ge.h               |  187 +++++++++++++++++++++++
 7 files changed, 444 insertions(+), 0 deletions(-)
 create mode 100644 board/Marvell/mv88f6281gtw_ge/Makefile
 create mode 100644 board/Marvell/mv88f6281gtw_ge/config.mk
 create mode 100644 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c
 create mode 100644 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h
 create mode 100644 include/configs/mv88f6281gtw_ge.h
MAKEALL +1 -0
index c98d03a..6719d7b 100755
@@ -505,6 +505,7 @@ LIST_ARM9="			\
 	cp946es			\
 	cp966			\
 	lpd7a400		\
+	mv88f6281gtw_ge		\
 	mx1ads			\
 	mx1fs2			\
 	netstar			\
Makefile +3 -0
index 81a5cd0..8144ecd 100644
@@ -2808,6 +2808,9 @@ lpd7a400_config \
 lpd7a404_config:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm lh7a40x lpd7a40x
 
+mv88f6281gtw_ge_config: unconfig
+	@$(MKCONFIG) $(@:_config=) arm arm926ejs $(@:_config=) Marvell kirkwood
+
 mx1ads_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t mx1ads NULL imx
 
board/Marvell/mv88f6281gtw_ge/Makefile new file +51 -0

51 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/config.mk new file +25 -0
new file mode 100644
index 0000000..fb29a1b
@@ -0,0 +1,25 @@
+#
+# (C) Copyright 2009
+# Marvell Semiconductor <www.marvell.com>
+# Prafulla Wadaskar <[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
+#
+
+TEXT_BASE = 0x00600000
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +141 -0

141 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h new file +36 -0
new file mode 100644
index 0000000..38ebfbe
@@ -0,0 +1,36 @@
+/*
+ * (C) Copyright 2009
+ * Marvell Semiconductor <www.marvell.com>
+ * Prafulla Wadaskar <[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 __MV88F6281GTW_GE_H
+#define __MV88F6281GTW_GE_H
+
+#define MV88F6281GTW_GE_OE_LOW		(~((1 << 7) | (1 << 12) \
+					  |(1 << 20) | (1 << 21)))	/*enable GLED,RLED */
+#define MV88F6281GTW_GE_OE_HIGH		(~((1 << 4)|(1 << 6)|(1 << 7)|(1 << 12) \
+					  |(1 << 13)|(1 << 16)|(1 << 17)))
+#define MV88F6281GTW_GE_OE_VAL_LOW	(1 << 20)	/*make GLED on */
+#define MV88F6281GTW_GE_OE_VAL_HIGH	((1 << 6)|(1 << 13)|(1 << 16)|(1 << 17))
+
+
+#endif /* __MV88F6281GTW_GE_H */
include/configs/mv88f6281gtw_ge.h new file +187 -0

187 lines not on this page · raw message

Signature · 1 line
1.5.3.3
#7 lore raw

PATCH v9 1/1 Marvell MV88F6281GTW_GE Board support

Dear Prafulla Wadaskar,

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

This is Marvell's 88F6281_A0 based custom board developed for wireless access point product

...

include/configs/mv88f6281gtw_ge.h line 127

Quoted 10 lines
include/configs/mv88f6281gtw_ge.h new file +10 -0
+/*
+ *  Environment variables configurations
+ */
+#ifdef CONFIG_SPI_FLASH
+#define CONFIG_ENV_IS_IN_SPI_FLASH	1
+#define CONFIG_ENV_SIZE			0x10000	/* spi flash block (64k) */
+#define CONFIG_ENV_SECT_SIZE		0x10000	/* _64K */
+#else
+#define CONFIG_ENV_IS_NOWHERE		1	/* if env in SDRAM */
+#define CONFIG_ENV_SIZE			0x20000	/* default 128k */

Just a question... Do you really NEED 64 kB or even 128 kB environement size? In my experience, 16 kB is almost always more than sufficient. Keep in mind that the environment size can be smaller than the sector size which stores the environment, and that a big enviroment size adds to the boot delay, as the whole environment size needs to be CRC32 checked.

include/configs/mv88f6281gtw_ge.h line 139

Quoted 7 lines

+ * Default environment variables
+ */

include/configs/mv88f6281gtw_ge.h new file +5 -0
+#define CONFIG_BOOTCOMMAND		"${x_bootcmd_kernel}; setenv bootargs " \
+	"${x_bootargs} ${x_bootargs_root}; bootm 0x6400000;"
+
+#define CONFIG_MTDPARTS			"spi0.0:512k(uboot),512k at 512k(psm), "	\
+	"2m at 1m(kernel),13m at 3m(rootfs)\0"

Lines too long.

Quoted 6 lines
include/configs/mv88f6281gtw_ge.h new file +6 -0
+#define CONFIG_EXTRA_ENV_SETTINGS	"x_bootargs=console=ttyS0,115200 " \
+	"mtdparts="CONFIG_MTDPARTS	\
+	"x_bootcmd_kernel=cp.b 0xf8100000 0x6400000 0x200000\0" \
+	"x_bootargs_root=root=/dev/mtdblock3 ro rootfstype=squashfs\0"
+
+/*

include/configs/mv88f6281gtw_ge.h line 156

Quoted 10 lines
include/configs/mv88f6281gtw_ge.h new file +10 -0
+ * Size of malloc() pool
+ */
+#define CONFIG_SYS_MALLOC_LEN	0x00400000	/* 4M */
+/* size in bytes reserved for initial data */
+#define CONFIG_SYS_GBL_DATA_SIZE	128
+
+/*
+ * Other required minimal configurations
+ */
+#define CONFIG_CONSOLE_INFO_QUIET	/* some code reduction */

Hm... you reserve 4 MB malloc space, but then suppress useful information to save a few bytes? To me this seems inconsistent. I recommend to check if this really makes sense.

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
C makes it easy for you to shoot yourself in the foot. C++ makes that
harder, but when you do, it blows away your whole leg.
                                                 -- Bjarne Stroustrup
#8 lore raw

PATCH v9 1/1 Marvell MV88F6281GTW_GE Board support

Dear Wolfgang Denk

Thanks for your comments..

Quoted 30 lines

-----Original Message-----
From: Wolfgang Denk [mailto:wd at denx.de]
Sent: Wednesday, May 20, 2009 2:51 PM
To: Prafulla Wadaskar
Cc: u-boot at lists.denx.de; Ashish Karkare; Prabhanjan Sarnaik; Ronen Shitrit
Subject: Re: [U-Boot] [PATCH v9] Marvell MV88F6281GTW_GE Board support

Dear Prafulla Wadaskar,

In message

Quoted 2 lines · <[email protected]> you wrote:

This is Marvell's 88F6281_A0 based custom board developed

for wireless

Quoted 1 line

access point product

...

Quoted 2 lines

+/*
+ * Environment variables configurations */ #ifdef

CONFIG_SPI_FLASH

Review

Quoted 2 lines
(quoted diff) +2 -0
+#define CONFIG_ENV_IS_IN_SPI_FLASH	1
+#define CONFIG_ENV_SIZE			0x10000	/* spi 

flash block (64k) */

include/configs/mv88f6281gtw_ge.h

Quoted 3 lines
include/configs/mv88f6281gtw_ge.h new file +3 -0
+#define CONFIG_ENV_SECT_SIZE		0x10000	/* _64K */
+#else
+#define CONFIG_ENV_IS_NOWHERE		1	/* if 

env in SDRAM */

Quoted 1 line

+#define CONFIG_ENV_SIZE 0x20000 /*

default 128k */

Quoted 7 lines

Just a question... Do you really NEED 64 kB or even 128 kB environement size? In my experience, 16 kB is almost always more than sufficient. Keep in mind that the environment size can be smaller than the sector size which stores the environment, and that a big enviroment size adds to the boot delay, as the whole environment size needs to be CRC32 checked.

I agree, even 4kb is sufficient for me
but if I keep it less than a sector size it gives me bad CRC warning at boot up even though I do saveenv Hence I kept it equal to sector size
This may be a bug...??

Quoted 5 lines
Quoted 5 lines

+ * Default environment variables
+ */
+#define CONFIG_BOOTCOMMAND "${x_bootcmd_kernel};

Quoted 8 lines

setenv bootargs " \

include/configs/mv88f6281gtw_ge.h

Quoted 3 lines
include/configs/mv88f6281gtw_ge.h new file +3 -0
+	"${x_bootargs} ${x_bootargs_root}; bootm 0x6400000;"
+
+#define CONFIG_MTDPARTS			

"spi0.0:512k(uboot),512k at 512k(psm), " \

include/configs/mv88f6281gtw_ge.h line 139

Quoted 1 line
include/configs/mv88f6281gtw_ge.h new file +1 -0
+	"2m at 1m(kernel),13m at 3m(rootfs)\0"

Lines too long.

Corrected....

Quoted 13 lines
Quoted 2 lines

+#define CONFIG_EXTRA_ENV_SETTINGS

"x_bootargs=console=ttyS0,115200 " \

Quoted 10 lines
include/configs/mv88f6281gtw_ge.h new file +10 -0
+	"mtdparts="CONFIG_MTDPARTS	\
+	"x_bootcmd_kernel=cp.b 0xf8100000 0x6400000 0x200000\0" \
+	"x_bootargs_root=root=/dev/mtdblock3 ro rootfstype=squashfs\0"
+
+/*
+ * Size of malloc() pool
+ */
+#define CONFIG_SYS_MALLOC_LEN	0x00400000	/* 4M */
+/* size in bytes reserved for initial data */
+#define CONFIG_SYS_GBL_DATA_SIZE	128
Quoted 8 lines

include/configs/mv88f6281gtw_ge.h line 156

Quoted 4 lines
include/configs/mv88f6281gtw_ge.h new file +4 -0
+
+/*
+ * Other required minimal configurations  */
+#define CONFIG_CONSOLE_INFO_QUIET	/* some code reduction */

Hm... you reserve 4 MB malloc space, but then suppress
useful information to save a few bytes? To me this seems
inconsistent. I recommend to check if this really makes sense.

I changed it to 128KB refering some other similar boards..

Regards..
Prafulla ..

#9 lore raw

PATCH v9 1/1 Marvell MV88F6281GTW_GE Board support

Quoted 15 lines
Quoted 9 lines
Quoted 1 line

+ * Environment variables configurations */ #ifdef

CONFIG_SPI_FLASH

Review

Quoted 2 lines
(quoted diff) +2 -0
+#define CONFIG_ENV_IS_IN_SPI_FLASH	1
+#define CONFIG_ENV_SIZE			0x10000	/* spi 

flash block (64k) */

include/configs/mv88f6281gtw_ge.h

Quoted 3 lines
include/configs/mv88f6281gtw_ge.h new file +3 -0
+#define CONFIG_ENV_SECT_SIZE		0x10000	/* _64K */
+#else
+#define CONFIG_ENV_IS_NOWHERE		1	/* if 

env in SDRAM */

Quoted 6 lines
Quoted 1 line

+#define CONFIG_ENV_SIZE 0x20000 /*

default 128k */

Just a question... Do you really NEED 64 kB or even 128 kB environement size? In my experience, 16 kB is almost always more than sufficient. Keep in mind that the environment

Quoted 8 lines

size can

Quoted 3 lines

be smaller than the sector size which stores the environment, and that a big enviroment size adds to the boot delay, as the whole environment size needs to be CRC32 checked.

I agree, even 4kb is sufficient for me
but if I keep it less than a sector size it gives me bad CRC warning at boot up even though I do saveenv Hence I kept it equal to sector size This may be a bug...??

Hi Wolfgang
This was really a bug in my spi driver, I fixed it,
now it's working for any size (even 4k)
Thanks for pointing this issue, I am using CONFIG_ENV_SIZE = 4k now

Regards..
Prafulla . .

#10 lore raw

PATCH v9 1/1 Marvell MV88F6281GTW_GE Board support

In reply to Prafulla Wadaskar

Dear Prafulla Wadaskar,

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

Just a question... Do you really NEED 64 kB or even =20 128 kB environement size? In my experience, 16 kB is almost=20 always more than sufficient. Keep in mind that the=20 environment size can be smaller than the sector size which=20 stores the environment, and that a big enviroment size=20 adds to the boot delay, as the whole environment size needs=20 to be CRC32 checked.

Quoted 5 lines

I agree, even 4kb is sufficient for me
but if I keep it less than a sector size it gives me bad CRC warning at boo= t up even though I do saveenv
Hence I kept it equal to sector size
This may be a bug...??

This is indeed a bug, then. To give you an example - in "include/configs/TQM5200.h" we have:

	#define CONFIG_ENV_SIZE         0x4000  /* 16 k - keep small for fast booting */
	...
	#define CONFIG_ENV_SECT_SIZE    0x40000

This works fine - CRC computation covers only the 16 k as set in CONFIG_ENV_SIZE.

It seems you really have a bug there, which should be fixed.

Best regards,

Wolfgang Denk

Signature · 8 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
COMPONENT EQUIVALENCY NOTICE:  The  Subatomic  Particles  (Electrons,
Protons,  etc.) Comprising This Product Are Exactly the Same in Every
Measurable Respect as Those Used in the Products of Other  Manufactu-
rers,  and  No Claim to the Contrary May Legitimately Be Expressed or
Implied.
#11 lore raw

PATCH v9 1/1 Marvell MV88F6281GTW_GE Board support

Quoted 8 lines
Quoted 5 lines
Quoted 5 lines

Just a question... Do you really NEED 64 kB or even =20 128 kB environement size? In my experience, 16 kB is almost=20 always more than sufficient. Keep in mind that the=20 environment size can be smaller than the sector size

which=20 stores

Quoted 1 line
Quoted 1 line

the environment, and that a big enviroment size=20

adds to the

Quoted 8 lines
Quoted 4 lines
Quoted 2 lines

boot delay, as the whole environment size needs=20 to be CRC32 checked.

I agree, even 4kb is sufficient for me but if I keep it less than a sector size it gives me bad CRC warning at boo= t up even

though I do

Quoted 1 line

saveenv Hence I kept it equal to sector size This may be a bug...??

This is indeed a bug, then. To give you an example - in

Yes, I have resolved it in v9 and posted :-)
Thanks and regards...
Prafulla . .

#12 lore raw

PATCH v10 1/1 Marvell MV88F6281GTW_GE Board support

From: prafulla_wadaskar <[email protected]>

This is Marvell's 88F6281_A0 based custom board developed for wireless access point product

This patch is tested for-
1. Boot from DRAM/SPI flash/NFS
2. File transfer using tftp and loadb
3. SPI flash read/write/erase
4. Booting Linux kernel and RFS from SPI flash

---
Change log
v2: updated as per first review comments debug_prints updated to debug

v3: updaed as per review comments for v2 added mv88f6281gtw_ge.h file removed BITxx macros

v4: updated as per review comments for v3 arch_misc_init support is added and used from kirkwood

v5: updated as per review comments for v4 CONFIG_MACH_MV88F6281GTW_GE added more comments added and serial configuration removed from mv88f6281gtw_ge.c

V6: clean switch configuration using netdev.h

v7: Marvell copyright removed from u-boot.lds Maintainer added for this board

v8: u-boot.lds removed
finetuned for cosmetic and switch related changes

v9: new mpp configuration used
CONFIG_ARCH_LOWLEVEL_INIT defination removed

v10: CONFIG_ENV_SIZE set to 4kb
CONFIG_SYS_MALLOC_LEN set to 128kb

 MAKEALL                                         |    1 +
 Makefile                                        |    3 +
 board/Marvell/mv88f6281gtw_ge/Makefile          |   51 ++++++
 board/Marvell/mv88f6281gtw_ge/config.mk         |   25 +++
 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c |  141 +++++++++++++++++
 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h |   36 +++++
 include/configs/mv88f6281gtw_ge.h               |  187 +++++++++++++++++++++++
 7 files changed, 444 insertions(+), 0 deletions(-)
 create mode 100644 board/Marvell/mv88f6281gtw_ge/Makefile
 create mode 100644 board/Marvell/mv88f6281gtw_ge/config.mk
 create mode 100644 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c
 create mode 100644 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h
 create mode 100644 include/configs/mv88f6281gtw_ge.h
MAKEALL +1 -0
index c98d03a..6719d7b 100755
@@ -505,6 +505,7 @@ LIST_ARM9="			\
 	cp946es			\
 	cp966			\
 	lpd7a400		\
+	mv88f6281gtw_ge		\
 	mx1ads			\
 	mx1fs2			\
 	netstar			\
Makefile +3 -0
index 81a5cd0..8144ecd 100644
@@ -2808,6 +2808,9 @@ lpd7a400_config \
 lpd7a404_config:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm lh7a40x lpd7a40x
 
+mv88f6281gtw_ge_config: unconfig
+	@$(MKCONFIG) $(@:_config=) arm arm926ejs $(@:_config=) Marvell kirkwood
+
 mx1ads_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t mx1ads NULL imx
 
board/Marvell/mv88f6281gtw_ge/Makefile new file +51 -0

51 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/config.mk new file +25 -0
new file mode 100644
index 0000000..fb29a1b
@@ -0,0 +1,25 @@
+#
+# (C) Copyright 2009
+# Marvell Semiconductor <www.marvell.com>
+# Prafulla Wadaskar <[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
+#
+
+TEXT_BASE = 0x00600000
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +141 -0

141 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h new file +36 -0
new file mode 100644
index 0000000..fb0e571
@@ -0,0 +1,36 @@
+/*
+ * (C) Copyright 2009
+ * Marvell Semiconductor <www.marvell.com>
+ * Prafulla Wadaskar <[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 __MV88F6281GTW_GE_H
+#define __MV88F6281GTW_GE_H
+
+#define MV88F6281GTW_GE_OE_LOW		(~((1 << 7) | (1 << 12) \
+					  |(1 << 20) | (1 << 21)))	/*enable GLED,RLED */
+#define MV88F6281GTW_GE_OE_HIGH		(~((1 << 4)|(1 << 6)|(1 << 7)|(1 << 12) \
+					  |(1 << 13)|(1 << 16)|(1 << 17)))
+#define MV88F6281GTW_GE_OE_VAL_LOW	(1 << 20)	/*make GLED on */
+#define MV88F6281GTW_GE_OE_VAL_HIGH	((1 << 6)|(1 << 13)|(1 << 16)|(1 << 17))
+
+
+#endif /* __MV88F6281GTW_GE_H */
include/configs/mv88f6281gtw_ge.h new file +187 -0

187 lines not on this page · raw message

Signature · 1 line
1.5.3.3
#13 lore raw

PATCH v10 1/1 Marvell MV88F6281GTW_GE Board support

Dear Prafulla Wadaskar,

board/Marvell/mv88f6281gtw_ge/Makefile line 4

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

This is Marvell's 88F6281_A0 based custom board developed for wireless access point product

board/Marvell/mv88f6281gtw_ge/Makefile new file +4 -0
@@ -0,0 +1,51 @@
+#
+# (C) Copyright 2009
+# Marvell Semiconductor <www.marvell.com>
+# Prafulla Wadaskar <[email protected]>

As mentioned before, this makes no sense. Either Marvell holds the copyright, or you do.

...

board/Marvell/mv88f6281gtw_ge/Makefile line 9

Quoted 5 lines
board/Marvell/mv88f6281gtw_ge/Makefile new file +5 -0
+#define CONFIG_MD5	/* get_random_hex on krikwood needs MD5 support */
+#define CONFIG_SKIP_LOWLEVEL_INIT	/* disable board lowlevel_init */
+#define CONFIG_KIRKWOOD_EGIGA_INIT	/* Enable GbePort0/1 for kernel */
+#define CONFIG_KIRKWOOD_PCIE_INIT	/* Enable PCIE Port0 for kernel */
+#define CONFIG_KIRKWOOD_RGMII_PAD_1V8	/* Set RGMII Pad voltage to 1.8V */

Line too long.

...

board/Marvell/mv88f6281gtw_ge/Makefile line 15

Quoted 6 lines
board/Marvell/mv88f6281gtw_ge/Makefile new file +6 -0
+/*
+ * For booting Linux, the board info and command line data
+ * have to be in the first 8 MB of memory, since this is
+ * the maximum mapped by the Linux kernel during initialization.
+ */
+#define	CONFIG_BOOTMAPSZ	(8 << 20)	/* Initial Memmap for Linux */

Ditto. Please also check other files.

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: [email protected]
Vor allem kein Gedanke! Nichts ist kompromittierender als ein  Gedan-
ke!            - Friedrich Wilhelm Nietzsche _Der Fall Wagner_ (1888)
#14 lore raw

PATCH v10 1/1 Marvell MV88F6281GTW_GE Board support

Quoted 20 lines

-----Original Message-----
From: Wolfgang Denk [mailto:wd at denx.de]
Sent: Friday, May 22, 2009 4:37 PM
To: Prafulla Wadaskar
Cc: u-boot at lists.denx.de; Ashish Karkare; Prabhanjan Sarnaik; Ronen Shitrit
Subject: Re: [U-Boot] [PATCH v10] Marvell MV88F6281GTW_GE Board support

Dear Prafulla Wadaskar,

In message

Quoted 2 lines · <[email protected]> you wrote:

This is Marvell's 88F6281_A0 based custom board developed

for wireless

Quoted 1 line

access point product

Quoted 10 lines

board/Marvell/mv88f6281gtw_ge/Makefile line 4

Quoted 7 lines
board/Marvell/mv88f6281gtw_ge/Makefile new file +4 -0
@@ -0,0 +1,51 @@
+#
+# (C) Copyright 2009
+# Marvell Semiconductor <www.marvell.com> # Prafulla Wadaskar 
+<[email protected]>

As mentioned before, this makes no sense. Either Marvell holds the copyright, or you do.

Marvell holds copyright, I will remove "prafulla at marvell.com" This is there from first submission in all the patches such comments in early feedback is more helpful....
I will correct and re-submit all patches...

Quoted 4 lines

board/Marvell/mv88f6281gtw_ge/Makefile line 5

Quoted 1 line
board/Marvell/mv88f6281gtw_ge/Makefile new file +1 -0
+#define CONFIG_KIRKWOOD_RGMII_PAD_1V8	/* Set RGMII 

Pad voltage to 1.8V */

Line too long.

BTW what is max allowed line size? All line are below 80 chars.

Regards..
Prafulla . .

#15 lore raw

PATCH v10 1/1 Marvell MV88F6281GTW_GE Board support

Quoted 7 lines
Quoted 3 lines

As mentioned before, this makes no sense. Either Marvell holds the copyright, or you do.

Marvell holds copyright, I will remove "prafulla at marvell.com" This is there from first submission in all the patches such comments in early feedback is more helpful....
I will correct and re-submit all patches...

Dear Woldgang Denk

I have posted two patches for with copyright statements corrected. Whereas I have updated them for all patches at my end. It make no sense to post a patch JUST for this change
I will post other patches with other (expected..) review feedback

Regards..
Prafulla ..

#16 lore raw

PATCH v10 1/1 Marvell MV88F6281GTW_GE Board support

In reply to Prafulla Wadaskar

Dear Prafulla Wadaskar,

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

As mentioned before, this makes no sense. Either Marvell holds the copyright, or you do.

Marvell holds copyright, I will remove "prafulla at marvell.com" This is there from first submission in all the patches such comments in early feedback is more helpful....

Yes, I am aware of this - sorry. You know how this works - you submit something, and the second after you hit the "send" botton you will see a blatant typo. Same here - I've scanned several versions of the files and did not realize this, but not it hit me.

Quoted 1 line

I will correct and re-submit all patches...

Thanks.

Quoted 5 lines
Quoted 4 lines
Quoted 1 line

+#define CONFIG_KIRKWOOD_RGMII_PAD_1V8 /* Set RGMII

Pad voltage to 1.8V */

Line too long.

BTW what is max allowed line size? All line are below 80 chars.

The maximum line is 80 characters. Please keep in mind that one TAB character may occupy several columns - I guess you measured the character count, and not the line length.

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
Use C++ to confuse your enemies; use C to produce stable code.
#17 lore raw

PATCH v10 1/1 Marvell MV88F6281GTW_GE Board support

Quoted 9 lines
Quoted 5 lines
Quoted 4 lines
Quoted 1 line

+#define CONFIG_KIRKWOOD_RGMII_PAD_1V8 /* Set RGMII

Pad voltage to 1.8V */

Line too long.

BTW what is max allowed line size? All line are below 80 chars.

The maximum line is 80 characters. Plpeease keep in mind that one TAB character may occupy several columns - I guess you measured the character count, and not the line length.

Hi Wolfgang Denk
I have counted 80 considering tabs as 8chars, and that's every where in the code, Hopefully your tool is having some different settings (ex. Tab size >8) then may be this is valid comment.

If you are using any specific opensource tool/script to fix/check indentation code (other than Lindent) and If you can share with me. That would help me to provide code in sync with your requirements..

Thanks and Regards..
Prafulla . .

#18 lore raw

PATCH v11 1/1 Marvell MV88F6281GTW_GE Board support

In reply to Prafulla Wadaskar

This is Marvell's 88F6281_A0 based custom board developed for wireless access point product

This patch is tested for-
1. Boot from DRAM/SPI flash/NFS
2. File transfer using tftp and loadb
3. SPI flash read/write/erase
4. Booting Linux kernel and RFS from SPI flash

---
Change log
v2: updated as per first review comments debug_prints updated to debug

v3: updaed as per review comments for v2 added mv88f6281gtw_ge.h file removed BITxx macros

v4: updated as per review comments for v3 arch_misc_init support is added and used from kirkwood

v5: updated as per review comments for v4 CONFIG_MACH_MV88F6281GTW_GE added more comments added and serial configuration removed from mv88f6281gtw_ge.c

V6: clean switch configuration using netdev.h

v7: Marvell copyright removed from u-boot.lds Maintainer added for this board

v8: u-boot.lds removed
finetuned for cosmetic and switch related changes

v9: new mpp configuration used
CONFIG_ARCH_LOWLEVEL_INIT defination removed

v10: CONFIG_ENV_SIZE set to 4kb
CONFIG_SYS_MALLOC_LEN set to 128kb

v11: updated as per feedback for v10
copyright statement corrected
mtdparts definition corrected
all code lines checked for max len 80 chars

 MAKEALL                                         |    1 +
 Makefile                                        |    3 +
 board/Marvell/mv88f6281gtw_ge/Makefile          |   51 +++++++
 board/Marvell/mv88f6281gtw_ge/config.mk         |   25 +++
 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c |  141 ++++++++++++++++++
 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h |   36 +++++
 include/configs/mv88f6281gtw_ge.h               |  182 +++++++++++++++++++++++
 7 files changed, 439 insertions(+), 0 deletions(-)
 create mode 100644 board/Marvell/mv88f6281gtw_ge/Makefile
 create mode 100644 board/Marvell/mv88f6281gtw_ge/config.mk
 create mode 100644 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c
 create mode 100644 board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h
 create mode 100644 include/configs/mv88f6281gtw_ge.h
MAKEALL +1 -0
index c98d03a..6719d7b 100755
@@ -505,6 +505,7 @@ LIST_ARM9="			\
 	cp946es			\
 	cp966			\
 	lpd7a400		\
+	mv88f6281gtw_ge		\
 	mx1ads			\
 	mx1fs2			\
 	netstar			\
Makefile +3 -0
index 81a5cd0..8144ecd 100644
@@ -2808,6 +2808,9 @@ lpd7a400_config \
 lpd7a404_config:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm lh7a40x lpd7a40x
 
+mv88f6281gtw_ge_config: unconfig
+	@$(MKCONFIG) $(@:_config=) arm arm926ejs $(@:_config=) Marvell kirkwood
+
 mx1ads_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t mx1ads NULL imx
 
board/Marvell/mv88f6281gtw_ge/Makefile new file +51 -0

51 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/config.mk new file +25 -0
new file mode 100644
index 0000000..a4ea769
@@ -0,0 +1,25 @@
+#
+# (C) Copyright 2009
+# Marvell Semiconductor <www.marvell.com>
+# Written-by: Prafulla Wadaskar <[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
+#
+
+TEXT_BASE = 0x00600000
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +141 -0

141 lines not on this page · raw message

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.h new file +36 -0
new file mode 100644
index 0000000..65b925d
@@ -0,0 +1,36 @@
+/*
+ * (C) Copyright 2009
+ * Marvell Semiconductor <www.marvell.com>
+ * Written-by: Prafulla Wadaskar <[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 __MV88F6281GTW_GE_H
+#define __MV88F6281GTW_GE_H
+
+#define MV88F6281GTW_GE_OE_LOW		(~((1 << 7) | (1 << 12) \
+					  |(1 << 20) | (1 << 21)))
+#define MV88F6281GTW_GE_OE_HIGH	(~((1 << 4)|(1 << 6)|(1 << 7)|(1 << 12) \
+					  |(1 << 13)|(1 << 16)|(1 << 17)))
+#define MV88F6281GTW_GE_OE_VAL_LOW	(1 << 20)	/*make GLED on */
+#define MV88F6281GTW_GE_OE_VAL_HIGH	((1 << 6)|(1 << 13)|(1 << 16)|(1 << 17))
+
+
+#endif /* __MV88F6281GTW_GE_H */
include/configs/mv88f6281gtw_ge.h new file +182 -0

182 lines not on this page · raw message

Signature · 1 line
1.5.3.3
#19 lore raw

PATCH v10 1/1 Marvell MV88F6281GTW_GE Board support

In reply to Prafulla Wadaskar

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c line 31

Quoted 7 lines

+ */

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +6 -0
+
+#include <common.h>
+#include <netdev.h>
+#include <asm/arch/kirkwood.h>
+#include <asm/arch/mpp.h>
+#include "mv88f6281gtw_ge.h"

please move the mv88f6281gtw_ge.h
to include/asm-arm/arch-kirkwood/

Quoted 6 lines
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +6 -0
+
+DECLARE_GLOBAL_DATA_PTR;
+
+int board_init(void)
+{
+	/*

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c line 47

Quoted 10 lines
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +10 -0
+	 * default gpio configuration
+	 * There are maximum 64 gpios controlled through 2 sets of registers
+	 * the  below configuration configures mainly initial LED status
+	 */
+	kw_config_gpio(MV88F6281GTW_GE_OE_VAL_LOW,
+			MV88F6281GTW_GE_OE_VAL_HIGH,
+			MV88F6281GTW_GE_OE_LOW, MV88F6281GTW_GE_OE_HIGH);
+
+	/* Multi-Purpose Pins Functionality configuration */
+	u32 kwmpp_config[] = {

do you really need to configure all of this IO?

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c line 51

Quoted 4 lines
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +4 -0
+		MPP0_SPI_SCn,
+		MPP1_SPI_MOSI,
+		MPP2_SPI_SCK,
+		MPP3_SPI_MISO,

please add a device init api as done for davinci or at91 (could be done in an other patch)

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c line 56

Quoted 5 lines
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +5 -0
+		MPP4_GPIO,
+		MPP5_GPO,
+		MPP6_SYSRST_OUTn,
+		MPP7_SPI_SCn,
+		MPP8_TW_SDA,

Best Regards,
J.

#20 lore raw

PATCH v10 1/1 Marvell MV88F6281GTW_GE Board support

Quoted 9 lines

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c line 31

Quoted 7 lines

+ */

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +6 -0
+
+#include <common.h>
+#include <netdev.h>
+#include <asm/arch/kirkwood.h>
+#include <asm/arch/mpp.h>
+#include "mv88f6281gtw_ge.h"

please move the mv88f6281gtw_ge.h
to include/asm-arm/arch-kirkwood/

Sure... I will do it :-)

Quoted 12 lines

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c

Quoted 5 lines
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +5 -0
+int board_init(void)
+{
+	/*
+	 * default gpio configuration
+	 * There are maximum 64 gpios controlled through 2 sets 

of registers

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c

Quoted 5 lines
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +5 -0
+	 * the  below configuration configures mainly initial LED status
+	 */
+	kw_config_gpio(MV88F6281GTW_GE_OE_VAL_LOW,
+			MV88F6281GTW_GE_OE_VAL_HIGH,
+			MV88F6281GTW_GE_OE_LOW, 

MV88F6281GTW_GE_OE_HIGH);

Quoted 4 lines

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c line 47

Quoted 3 lines
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +3 -0
+
+	/* Multi-Purpose Pins Functionality configuration */
+	u32 kwmpp_config[] = {

do you really need to configure all of this IO?

Yes
I device needs all IO initializations done to make sure unused MPPs must be configured to GPIOs. This is required to reduce overall boards noise that we have identified through h/w test in the lab

Quoted 6 lines

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c line 51

Quoted 4 lines
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +4 -0
+		MPP0_SPI_SCn,
+		MPP1_SPI_MOSI,
+		MPP2_SPI_SCK,
+		MPP3_SPI_MISO,

please add a device init api as done for davinci or at91 (could be done in an other patch)

I could not get any reference for davinci or at91 for "device_init" Can you please provide me a specific pointer ?

OR do you mean to create new api "device_init" to do soc/device specific init ?
I think this is really not required here since it is specific to kirkwood implementation and may not apply for other architectures.

In my opinion we do not need any specific init here in this code... Pls clarify...

Regards..
Prafulla . .

#21 lore raw

PATCH v10 1/1 Marvell MV88F6281GTW_GE Board support

Quoted 11 lines · On Monday 25 May 2009 06:48:40 Prafulla Wadaskar wrote:
Quoted 10 lines

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c line 31

Quoted 7 lines

+ */

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +6 -0
+
+#include <common.h>
+#include <netdev.h>
+#include <asm/arch/kirkwood.h>
+#include <asm/arch/mpp.h>
+#include "mv88f6281gtw_ge.h"

please move the mv88f6281gtw_ge.h
to include/asm-arm/arch-kirkwood/

Quoted 1 line

Sure... I will do it :-)

Sorry for the late reply, but for my taste such board specific headers don't belong into the "common" include/asm-arch/arch-kirkwood directory. The original location in the board directory is the best place (IMHO).

Quoted 38 lines
Quoted 16 lines

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c

Quoted 5 lines
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +5 -0
+int board_init(void)
+{
+	/*
+	 * default gpio configuration
+	 * There are maximum 64 gpios controlled through 2 sets

of registers

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c

Quoted 5 lines
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +5 -0
+	 * the  below configuration configures mainly initial LED status
+	 */
+	kw_config_gpio(MV88F6281GTW_GE_OE_VAL_LOW,
+			MV88F6281GTW_GE_OE_VAL_HIGH,
+			MV88F6281GTW_GE_OE_LOW,

MV88F6281GTW_GE_OE_HIGH);

Quoted 5 lines

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c line 47

Quoted 3 lines
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +3 -0
+
+	/* Multi-Purpose Pins Functionality configuration */
+	u32 kwmpp_config[] = {

do you really need to configure all of this IO?

Yes
I device needs all IO initializations done to make sure unused MPPs must be configured to GPIOs. This is required to reduce overall boards noise that we have identified through h/w test in the lab

Quoted 7 lines

board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c line 51

Quoted 4 lines
board/Marvell/mv88f6281gtw_ge/mv88f6281gtw_ge.c new file +4 -0
+		MPP0_SPI_SCn,
+		MPP1_SPI_MOSI,
+		MPP2_SPI_SCK,
+		MPP3_SPI_MISO,

please add a device init api as done for davinci or at91 (could be done in an other patch)

I could not get any reference for davinci or at91 for "device_init" Can you please provide me a specific pointer ?

Quoted 6 lines

OR do you mean to create new api "device_init" to do soc/device specific init ? I think this is really not required here since it is specific to kirkwood implementation and may not apply for other architectures.

In my opinion we do not need any specific init here in this code... Pls clarify...

I think the current code version is fine. We don't need to create an over- complex API here.

Thanks.

Best regards,
Stefan

=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================