Skip to contentSkip to conversation

Add support for Eukrea CPUAT91 SBC

PATCH Superseded Eric Benard 5 participants 28 messages Jul 16, 2009 – Aug 9, 2009

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

CPUAT91 is built around Atmel's AT91RM9200 and has up to 16MB of NOR flash, up to 128MB of SDRAM, and includes a Micrel KS8721 PHY in RMII mode.

---
 MAINTAINERS                     |    6 +-
 MAKEALL                         |    3 +-
 Makefile                        |   16 +++
 board/eukrea/cpuat91/Makefile   |   50 ++++++++
 board/eukrea/cpuat91/config.mk  |    1 +
 board/eukrea/cpuat91/cpuat91.c  |   85 ++++++++++++++
 cpu/arm920t/at91rm9200/Makefile |    5 +-
 cpu/arm920t/at91rm9200/ks8721.c |  244 +++++++++++++++++++++++++++++++++++++++
 include/configs/cpuat91.h       |  231 ++++++++++++++++++++++++++++++++++++
 include/ks8721.h                |   78 +++++++++++++
 10 files changed, 715 insertions(+), 4 deletions(-)
 create mode 100644 board/eukrea/cpuat91/Makefile
 create mode 100644 board/eukrea/cpuat91/config.mk
 create mode 100644 board/eukrea/cpuat91/cpuat91.c
 create mode 100644 cpu/arm920t/at91rm9200/ks8721.c
 create mode 100644 include/configs/cpuat91.h
 create mode 100644 include/ks8721.h
MAINTAINERS +5 -1
index 575a7ec..da64571 100644
@@ -1,4 +1,4 @@
-#########################################################################
+9#########################################################################
 #									#
 # Regular Maintainers for U-Boot board support:				#
 #									#
@@ -515,6 +515,10 @@ Dirk Behme <[email protected]>
 
 	omap3_beagle	ARM CORTEX-A8 (OMAP3530 SoC)
 
+Eric Benard <[email protected]>
+
+	cpcuat91	ARM920T
+
 Rishi Bhattacharya <[email protected]>
 
 	omap5912osk	ARM926EJS
MAKEALL +2 -1
index 020ff73..0e0b657 100755
@@ -587,11 +587,12 @@ LIST_at91="			\
 	at91sam9260ek		\
 	at91sam9261ek		\
 	at91sam9263ek		\
-	at91sam9g10ek	\
+	at91sam9g10ek		\
 	at91sam9g20ek		\
 	at91sam9m10g45ek	\
 	at91sam9rlek		\
 	cmc_pu2			\
+	cpuat91			\
 	csb637			\
 	kb9202			\
 	meesc			\
Makefile +16 -0
index 090e645..02efe1b 100644
@@ -2683,6 +2683,22 @@ at91rm9200ek_config	:	unconfig
 cmc_pu2_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t cmc_pu2 NULL at91rm9200
 
+xtract_cpuat91 = $(subst _ram,, $(subst _config,,$1))
+
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_CPUAT91_RAM 1" >> ./include/config.h ; \
+	fi;
+	@$(MKCONFIG) -a $(call xtract_cpuat91,$@) arm arm920t cpuat91 eukrea at91rm9200
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_CPUAT91_RAM 1" >> ./include/config.h ; \
+		echo "... CPUAT91 configured for RAM !" ; \
+	else \
+		echo "#define CONFIG_BOOTDELAY 1" >> ./include/config.h ;\
+		echo "... CPUAT91 configure for Flash !" ;\
+	fi;
+
 csb637_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t csb637 NULL at91rm9200
 
board/eukrea/cpuat91/Makefile new file +50 -0

50 lines not on this page · raw message

board/eukrea/cpuat91/config.mk new file +1 -0
new file mode 100644
index 0000000..ef8dda0
@@ -0,0 +1 @@
+TEXT_BASE = 0x21F00000
board/eukrea/cpuat91/cpuat91.c new file +85 -0

85 lines not on this page · raw message

cpu/arm920t/at91rm9200/Makefile +3 -2
index 73aeeac..114d8ad 100644
@@ -31,14 +31,15 @@ COBJS	+= bcm5221.o
 COBJS	+= dm9161.o
 COBJS	+= ether.o
 COBJS	+= i2c.o
+COBJS-$(CONFIG_KS8721_PHY)	+= ks8721.o
 COBJS	+= lxt972.o
 COBJS	+= reset.o
 COBJS	+= spi.o
 COBJS	+= timer.o
 COBJS	+= usb.o
 
-SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
-OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS))
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS-y))
 
 all:	$(obj).depend $(LIB)
 
cpu/arm920t/at91rm9200/ks8721.c new file +244 -0

244 lines not on this page · raw message

include/configs/cpuat91.h new file +231 -0

231 lines not on this page · raw message

include/ks8721.h new file +78 -0

78 lines not on this page · raw message

Signature · 1 line
1.6.0.4
#1 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

Quoted 68 lines · Eric Benard

CPUAT91 is built around Atmel's AT91RM9200 and has up to 16MB of NOR flash, up to 128MB of SDRAM, and includes a Micrel KS8721 PHY in RMII mode.

---
 MAINTAINERS                     |    6 +-
 MAKEALL                         |    3 +-
 Makefile                        |   16 +++
 board/eukrea/cpuat91/Makefile   |   50 ++++++++
 board/eukrea/cpuat91/config.mk  |    1 +
 board/eukrea/cpuat91/cpuat91.c  |   85 ++++++++++++++
 cpu/arm920t/at91rm9200/Makefile |    5 +-
 cpu/arm920t/at91rm9200/ks8721.c |  244 +++++++++++++++++++++++++++++++++++++++
 include/configs/cpuat91.h       |  231 ++++++++++++++++++++++++++++++++++++
 include/ks8721.h                |   78 +++++++++++++
 10 files changed, 715 insertions(+), 4 deletions(-)
 create mode 100644 board/eukrea/cpuat91/Makefile
 create mode 100644 board/eukrea/cpuat91/config.mk
 create mode 100644 board/eukrea/cpuat91/cpuat91.c
 create mode 100644 cpu/arm920t/at91rm9200/ks8721.c
 create mode 100644 include/configs/cpuat91.h
 create mode 100644 include/ks8721.h
MAINTAINERS +5 -1
index 575a7ec..da64571 100644
@@ -1,4 +1,4 @@
-#########################################################################
+9#########################################################################
 #									#
 # Regular Maintainers for U-Boot board support:				#
 #									#
@@ -515,6 +515,10 @@ Dirk Behme <[email protected]>
 
 	omap3_beagle	ARM CORTEX-A8 (OMAP3530 SoC)
 
+Eric Benard <[email protected]>
+
+	cpcuat91	ARM920T
+
 Rishi Bhattacharya <[email protected]>
 
 	omap5912osk	ARM926EJS
MAKEALL +2 -1
index 020ff73..0e0b657 100755
@@ -587,11 +587,12 @@ LIST_at91="			\
 	at91sam9260ek		\
 	at91sam9261ek		\
 	at91sam9263ek		\
-	at91sam9g10ek	\
+	at91sam9g10ek		\
 	at91sam9g20ek		\
 	at91sam9m10g45ek	\
 	at91sam9rlek		\
 	cmc_pu2			\
+	cpuat91			\
 	csb637			\
 	kb9202			\
 	meesc			\
Makefile +0 -0
index 090e645..02efe1b 100644

Makefile at91rm9200ek_config : unconfig · line 2686

Quoted 4 lines
Makefile +1 -0
@@ -2683,6 +2683,22 @@ at91rm9200ek_config	:	unconfig
 cmc_pu2_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t cmc_pu2 NULL at91rm9200
 
+xtract_cpuat91 = $(subst _ram,, $(subst _config,,$1))

no need please remove

Makefile at91rm9200ek_config : unconfig · line 2691

Quoted 5 lines
Makefile +5 -0
+
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_CPUAT91_RAM 1" >> ./include/config.h ; \

what is this ram config?
what is its goal?

Makefile at91rm9200ek_config : unconfig · line 2693

Quoted 2 lines
Makefile +2 -0
+	fi;
+	@$(MKCONFIG) -a $(call xtract_cpuat91,$@) arm arm920t cpuat91 eukrea at91rm9200

cpuat91 will be enough as you do not use other option

Quoted 11 lines
Makefile +8 -0
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_CPUAT91_RAM 1" >> ./include/config.h ; \
+		echo "... CPUAT91 configured for RAM !" ; \
+	else \
+		echo "#define CONFIG_BOOTDELAY 1" >> ./include/config.h ;\
+		echo "... CPUAT91 configure for Flash !" ;\
+	fi;
+
 csb637_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t csb637 NULL at91rm9200
 

<snip>

Quoted 28 lines
cpu/arm920t/at91rm9200/Makefile +3 -2
index 73aeeac..114d8ad 100644
@@ -31,14 +31,15 @@ COBJS	+= bcm5221.o
 COBJS	+= dm9161.o
 COBJS	+= ether.o
 COBJS	+= i2c.o
+COBJS-$(CONFIG_KS8721_PHY)	+= ks8721.o
 COBJS	+= lxt972.o
 COBJS	+= reset.o
 COBJS	+= spi.o
 COBJS	+= timer.o
 COBJS	+= usb.o
 
-SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
-OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS))
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS-y))
 
 all:	$(obj).depend $(LIB)
 
cpu/arm920t/at91rm9200/ks8721.c new file +0 -0
new file mode 100644
index 0000000..703e58c

cpu/arm920t/at91rm9200/ks8721.c line 6

Quoted 6 lines
cpu/arm920t/at91rm9200/ks8721.c new file +6 -0
@@ -0,0 +1,244 @@
+/*
+ * (C) Copyright 2006
+ * Author : Eric Benard (Eukrea Electromatique)
+ * based on dm9161.c which is :
+ * (C) Copyright 2003
+ * Author : Hamid Ikdoumi (Atmel)

I'm not a fan of this implementation at all

but as I've not yet finish the rm9200 cleanup
I'll ack this ben what do you think?
ben please note that the rm9200 cleanup will introduce a phylib support

Quoted 9 lines
cpu/arm920t/at91rm9200/ks8721.c new file +9 -0
+ *
+ * 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.
+ *

cpu/arm920t/at91rm9200/ks8721.c line 25

Quoted 10 lines
cpu/arm920t/at91rm9200/ks8721.c new file +10 -0
+ * 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., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ */

Best Regards,
J.

#2 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

Quoted 6 lines · Jean-Christophe PLAGNIOL-VILLARD

Makefile at91rm9200ek_config : unconfig · line 2691

Quoted 5 lines
Makefile +5 -0
+
+cpuat91_ram_config \
+cpuat91_config    :    unconfig
+    @if [ "$(findstring _ram_,$@)" ] ; then \
+        echo "#define CONFIG_CPUAT91_RAM 1" >> ./include/config.h ; \

what is this ram config?

the ram config allows to generate a u-boot without low level init and relocation without having to modify the .h config file.

Quoted 1 line

what is its goal?

to generate a u-boot.bin which can be used to bootstrap the AT91RM9200 through it's serial port (using Atmel's loader).

Best regards,
Eric

#3 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

Quoted 7 lines · Eric B?nard
Quoted 6 lines · Jean-Christophe PLAGNIOL-VILLARD

Makefile at91rm9200ek_config : unconfig · line 2691

Quoted 5 lines
Makefile +5 -0
+
+cpuat91_ram_config \
+cpuat91_config    :    unconfig
+    @if [ "$(findstring _ram_,$@)" ] ; then \
+        echo "#define CONFIG_CPUAT91_RAM 1" >> ./include/config.h ; \

what is this ram config?

Quoted 6 lines

the ram config allows to generate a u-boot without low level init and relocation without having to modify the .h config file.

Quoted 1 line

what is its goal?

to generate a u-boot.bin which can be used to bootstrap the AT91RM9200 through it's serial port (using Atmel's loader).

so no need to add a new config
just add
#define CONFIG_SKIP_LOWLEVEL_INIT
#define CONFIG_SKIP_RELOCATE_UBOOT
via the Makefile

Best Regards,
J.

#4 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

CPUAT91 is built around Atmel's AT91RM9200 and has up to 16MB of NOR flash, up to 128MB of SDRAM, and includes a Micrel KS8721 PHY in RMII mode.

---
 MAINTAINERS                     |    6 +-
 MAKEALL                         |    3 +-
 Makefile                        |   12 ++
 board/eukrea/cpuat91/Makefile   |   50 ++++++++
 board/eukrea/cpuat91/config.mk  |    1 +
 board/eukrea/cpuat91/cpuat91.c  |   85 ++++++++++++++
 cpu/arm920t/at91rm9200/Makefile |    5 +-
 cpu/arm920t/at91rm9200/ks8721.c |  244 +++++++++++++++++++++++++++++++++++++++
 include/configs/cpuat91.h       |  231 ++++++++++++++++++++++++++++++++++++
 include/ks8721.h                |   78 +++++++++++++
 10 files changed, 711 insertions(+), 4 deletions(-)
 create mode 100644 board/eukrea/cpuat91/Makefile
 create mode 100644 board/eukrea/cpuat91/config.mk
 create mode 100644 board/eukrea/cpuat91/cpuat91.c
 create mode 100644 cpu/arm920t/at91rm9200/ks8721.c
 create mode 100644 include/configs/cpuat91.h
 create mode 100644 include/ks8721.h
MAINTAINERS +5 -1
index 575a7ec..da64571 100644
@@ -1,4 +1,4 @@
-#########################################################################
+9#########################################################################
 #									#
 # Regular Maintainers for U-Boot board support:				#
 #									#
@@ -515,6 +515,10 @@ Dirk Behme <[email protected]>
 
 	omap3_beagle	ARM CORTEX-A8 (OMAP3530 SoC)
 
+Eric Benard <[email protected]>
+
+	cpcuat91	ARM920T
+
 Rishi Bhattacharya <[email protected]>
 
 	omap5912osk	ARM926EJS
MAKEALL +2 -1
index 020ff73..0e0b657 100755
@@ -587,11 +587,12 @@ LIST_at91="			\
 	at91sam9260ek		\
 	at91sam9261ek		\
 	at91sam9263ek		\
-	at91sam9g10ek	\
+	at91sam9g10ek		\
 	at91sam9g20ek		\
 	at91sam9m10g45ek	\
 	at91sam9rlek		\
 	cmc_pu2			\
+	cpuat91			\
 	csb637			\
 	kb9202			\
 	meesc			\
Makefile +12 -0
index 090e645..3b348d9 100644
@@ -2683,6 +2683,18 @@ at91rm9200ek_config	:	unconfig
 cmc_pu2_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t cmc_pu2 NULL at91rm9200
 
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@mkdir -p $(obj)include
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_CPUAT91_RAM 1" >>$(obj)include/config.h ; \
+		$(XECHO) "... CPUAT91 configured for RAM" ; \
+	else \
+		echo "#define CONFIG_BOOTDELAY 1" >>$(obj)include/config.h ;\
+		$(XECHO) "... CPUAT91 configured for Flash" ;\
+	fi;
+	@$(MKCONFIG) -a cpuat91 arm arm920t cpuat91 eukrea at91rm9200
+
 csb637_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t csb637 NULL at91rm9200
 
board/eukrea/cpuat91/Makefile new file +50 -0

50 lines not on this page · raw message

board/eukrea/cpuat91/config.mk new file +1 -0
new file mode 100644
index 0000000..ef8dda0
@@ -0,0 +1 @@
+TEXT_BASE = 0x21F00000
board/eukrea/cpuat91/cpuat91.c new file +85 -0

85 lines not on this page · raw message

cpu/arm920t/at91rm9200/Makefile +3 -2
index 73aeeac..114d8ad 100644
@@ -31,14 +31,15 @@ COBJS	+= bcm5221.o
 COBJS	+= dm9161.o
 COBJS	+= ether.o
 COBJS	+= i2c.o
+COBJS-$(CONFIG_KS8721_PHY)	+= ks8721.o
 COBJS	+= lxt972.o
 COBJS	+= reset.o
 COBJS	+= spi.o
 COBJS	+= timer.o
 COBJS	+= usb.o
 
-SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
-OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS))
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS-y))
 
 all:	$(obj).depend $(LIB)
 
cpu/arm920t/at91rm9200/ks8721.c new file +244 -0

244 lines not on this page · raw message

include/configs/cpuat91.h new file +231 -0

231 lines not on this page · raw message

include/ks8721.h new file +78 -0

78 lines not on this page · raw message

Signature · 1 line
1.6.0.4
#5 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

Dear Eric Benard,

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

CPUAT91 is built around Atmel's AT91RM9200 and has up to 16MB of NOR flash, up to 128MB of SDRAM, and includes a Micrel KS8721 PHY in RMII mode.

---

Your subject line reads:

[PATCH 1/1] Add support for Eukrea CPUAT91 SBC

Note that the "1/1" part is bogus as you submit just a single patch - please omit it.

Second, it seems that this is a resubmit of an earlier patch. You are suppposed to mark it as such, for example by using something like "[PATCH v2]" in the subject, and you are also supposed to include at least a short summary what has been changed compared to your previous version (add this here, i. e. below the "---" line).

MAINTAINERS line 1

Quoted 7 lines
MAINTAINERS +1 -1
index 575a7ec..da64571 100644
@@ -1,4 +1,4 @@
-#########################################################################
+9#########################################################################

^^^^^

Here you inserted garbage. Please fix.

board/eukrea/cpuat91/cpuat91.c line 46

Quoted 9 lines
board/eukrea/cpuat91/cpuat91.c new file +7 -0
+int board_init(void)
+{
+	/* Enable Ctrlc */
+	console_init_f();
+
+	/* memory and cpu-speed are setup before relocation */
+	/* so we do _nothing_ here */

Incorrect multi-line comment style.

Quoted 65 lines
board/eukrea/cpuat91/cpuat91.c new file +38 -0
+	/* arch number of CPUAT91-Board */
+	gd->bd->bi_arch_number = MACH_TYPE_CPUAT91;
+	/* adress of boot parameters */
+	gd->bd->bi_boot_params = PHYS_SDRAM + 0x100;
+
+	return 0;
+}
+
+int dram_init(void)
+{
+	gd->bd->bi_dram[0].start = PHYS_SDRAM;
+	gd->bd->bi_dram[0].size = PHYS_SDRAM_SIZE;
+	return 0;
+}
+
+#if defined(CONFIG_DRIVER_ETHER)
+#if defined(CONFIG_CMD_NET)
+
+/*
+ * Name:
+ *	at91rm9200_GetPhyInterface
+ * Description:
+ *	Initialise the interface functions to the PHY
+ * Arguments:
+ *	None
+ * Return value:
+ *	None
+ */
+void at91rm9200_GetPhyInterface(AT91PS_PhyOps p_phyops)
+{
+	p_phyops->Init = ks8721_InitPhy;
+	p_phyops->IsPhyConnected = ks8721_IsPhyConnected;
+	p_phyops->GetLinkSpeed = ks8721_GetLinkSpeed;
+	p_phyops->AutoNegotiate = ks8721_AutoNegotiate;
+}
+
+#endif	/* CONFIG_CMD_NET */
+#endif	/* CONFIG_DRIVER_ETHER */
cpu/arm920t/at91rm9200/Makefile +3 -2
index 73aeeac..114d8ad 100644
@@ -31,14 +31,15 @@ COBJS	+= bcm5221.o
 COBJS	+= dm9161.o
 COBJS	+= ether.o
 COBJS	+= i2c.o
+COBJS-$(CONFIG_KS8721_PHY)	+= ks8721.o
 COBJS	+= lxt972.o
 COBJS	+= reset.o
 COBJS	+= spi.o
 COBJS	+= timer.o
 COBJS	+= usb.o
 
-SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
-OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS))
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS-y))
 
 all:	$(obj).depend $(LIB)
 
cpu/arm920t/at91rm9200/ks8721.c new file +0 -0
new file mode 100644
index 0000000..703e58c

...

Quoted 4 lines

+ * Return value:
+ * TRUE - if id read successfully
+ * FALSE- if error
+ */

Please use 0 and 1 (or -1) as return values. We don't use TRUE and FALSE here.

...

cpu/arm920t/at91rm9200/ks8721.c line 126

Quoted 10 lines
cpu/arm920t/at91rm9200/ks8721.c new file +10 -0
+	if (stat1 & KS8721_10BASE_T_HD) {
+		/*set MII for 10BaseT and Half Duplex  */
+		printf("10BT HD\n");
+		p_mac->EMAC_CFG &= ~(AT91C_EMAC_SPD | AT91C_EMAC_FD);
+		return TRUE;
+	}
+	return FALSE;
+}
+
+

Please use only a single blank line here (and in similar places).

Quoted 5 lines
cpu/arm920t/at91rm9200/ks8721.c new file +5 -0
+/*
+ * Name:
+ *	ks8721_InitPhy
+ * Description:
+ *	MAC starts checking its link by using parallel detection and

cpu/arm920t/at91rm9200/ks8721.c line 141

Quoted 10 lines
cpu/arm920t/at91rm9200/ks8721.c new file +10 -0
+ *	Autonegotiation and the same is set in the MAC configuration registers
+ * Arguments:
+ *	p_mac - pointer to struct AT91S_EMAC
+ * Return value:
+ *	TRUE - if link status set succesfully
+ *	FALSE - if link status not set
+ */
+UCHAR ks8721_InitPhy(AT91PS_EMAC p_mac)
+{
+	UCHAR ret = TRUE;

Please get rid of UCHAR an the like.

cpu/arm920t/at91rm9200/ks8721.c line 144

Quoted 3 lines
cpu/arm920t/at91rm9200/ks8721.c new file +3 -0
+	unsigned short IntValue;
+
+	at91rm9200_EmacEnableMDIO(p_mac);

Please do not use CamelCase identifiers.

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
Our business is run on trust.  We trust you will pay in advance.
#6 lore raw

PATCH v3 1/1 Add support for Eukrea CPUAT91 SBC

CPUAT91 is built around Atmel's AT91RM9200 and has up to 16MB of NOR flash, up to 128MB of SDRAM, and includes a Micrel KS8721 PHY in RMII mode.

v3 : fix coding style issues

---
 MAINTAINERS                     |    4 +
 MAKEALL                         |    3 +-
 Makefile                        |   12 ++
 board/eukrea/cpuat91/Makefile   |   50 ++++++++
 board/eukrea/cpuat91/config.mk  |    1 +
 board/eukrea/cpuat91/cpuat91.c  |   86 ++++++++++++++
 cpu/arm920t/at91rm9200/Makefile |    5 +-
 cpu/arm920t/at91rm9200/ks8721.c |  242 +++++++++++++++++++++++++++++++++++++++
 include/configs/cpuat91.h       |  231 +++++++++++++++++++++++++++++++++++++
 include/ks8721.h                |   78 +++++++++++++
 10 files changed, 709 insertions(+), 3 deletions(-)
 create mode 100644 board/eukrea/cpuat91/Makefile
 create mode 100644 board/eukrea/cpuat91/config.mk
 create mode 100644 board/eukrea/cpuat91/cpuat91.c
 create mode 100644 cpu/arm920t/at91rm9200/ks8721.c
 create mode 100644 include/configs/cpuat91.h
 create mode 100644 include/ks8721.h
MAINTAINERS +4 -0
index 575a7ec..ed73b25 100644
@@ -515,6 +515,10 @@ Dirk Behme <[email protected]>
 
 	omap3_beagle	ARM CORTEX-A8 (OMAP3530 SoC)
 
+Eric Benard <[email protected]>
+
+	cpuat91		ARM920T
+
 Rishi Bhattacharya <[email protected]>
 
 	omap5912osk	ARM926EJS
MAKEALL +2 -1
index 020ff73..0e0b657 100755
@@ -587,11 +587,12 @@ LIST_at91="			\
 	at91sam9260ek		\
 	at91sam9261ek		\
 	at91sam9263ek		\
-	at91sam9g10ek	\
+	at91sam9g10ek		\
 	at91sam9g20ek		\
 	at91sam9m10g45ek	\
 	at91sam9rlek		\
 	cmc_pu2			\
+	cpuat91			\
 	csb637			\
 	kb9202			\
 	meesc			\
Makefile +12 -0
index 090e645..3b348d9 100644
@@ -2683,6 +2683,18 @@ at91rm9200ek_config	:	unconfig
 cmc_pu2_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t cmc_pu2 NULL at91rm9200
 
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@mkdir -p $(obj)include
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_CPUAT91_RAM 1" >>$(obj)include/config.h ; \
+		$(XECHO) "... CPUAT91 configured for RAM" ; \
+	else \
+		echo "#define CONFIG_BOOTDELAY 1" >>$(obj)include/config.h ;\
+		$(XECHO) "... CPUAT91 configured for Flash" ;\
+	fi;
+	@$(MKCONFIG) -a cpuat91 arm arm920t cpuat91 eukrea at91rm9200
+
 csb637_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t csb637 NULL at91rm9200
 
board/eukrea/cpuat91/Makefile new file +50 -0

50 lines not on this page · raw message

board/eukrea/cpuat91/config.mk new file +1 -0
new file mode 100644
index 0000000..ef8dda0
@@ -0,0 +1 @@
+TEXT_BASE = 0x21F00000
board/eukrea/cpuat91/cpuat91.c new file +86 -0

86 lines not on this page · raw message

cpu/arm920t/at91rm9200/Makefile +3 -2
index 73aeeac..114d8ad 100644
@@ -31,14 +31,15 @@ COBJS	+= bcm5221.o
 COBJS	+= dm9161.o
 COBJS	+= ether.o
 COBJS	+= i2c.o
+COBJS-$(CONFIG_KS8721_PHY)	+= ks8721.o
 COBJS	+= lxt972.o
 COBJS	+= reset.o
 COBJS	+= spi.o
 COBJS	+= timer.o
 COBJS	+= usb.o
 
-SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
-OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS))
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS-y))
 
 all:	$(obj).depend $(LIB)
 
cpu/arm920t/at91rm9200/ks8721.c new file +242 -0

242 lines not on this page · raw message

include/configs/cpuat91.h new file +231 -0

231 lines not on this page · raw message

include/ks8721.h new file +78 -0

78 lines not on this page · raw message

Signature · 1 line
1.6.0.4
#7 lore raw

PATCH v3 1/1 Add support for Eukrea CPUAT91 SBC

MAKEALL LIST_at91=" \ · line 590

Quoted 8 lines
MAKEALL +1 -1
@@ -587,11 +587,12 @@ LIST_at91="			\
 	at91sam9260ek		\
 	at91sam9261ek		\
 	at91sam9263ek		\
-	at91sam9g10ek	\
+	at91sam9g10ek		\

please do not touch non related part to your patch please fix it in an other patch

Quoted 13 lines
MAKEALL +1 -0
 	at91sam9g20ek		\
 	at91sam9m10g45ek	\
 	at91sam9rlek		\
 	cmc_pu2			\
+	cpuat91			\
 	csb637			\
 	kb9202			\
 	meesc			\
Makefile +0 -0
index 090e645..3b348d9 100644

Makefile at91rm9200ek_config : unconfig · line 2690

Quoted 8 lines
Makefile +5 -0
@@ -2683,6 +2683,18 @@ at91rm9200ek_config	:	unconfig
 cmc_pu2_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t cmc_pu2 NULL at91rm9200
 
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@mkdir -p $(obj)include
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_CPUAT91_RAM 1" >>$(obj)include/config.h ; \

same as other patch
no need please define the
#define CONFIG_SKIP_LOWLEVEL_INIT
#define CONFIG_SKIP_RELOCATE_UBOOT
here

Quoted 34 lines
Makefile +7 -0
+		$(XECHO) "... CPUAT91 configured for RAM" ; \
+	else \
+		echo "#define CONFIG_BOOTDELAY 1" >>$(obj)include/config.h ;\
+		$(XECHO) "... CPUAT91 configured for Flash" ;\
+	fi;
+	@$(MKCONFIG) -a cpuat91 arm arm920t cpuat91 eukrea at91rm9200
+
 csb637_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t csb637 NULL at91rm9200
 
board/eukrea/cpuat91/Makefile new file +18 -0
new file mode 100644
index 0000000..08a90dc
@@ -0,0 +1,50 @@
+#
+# (C) Copyright 2003-2006
+# Wolfgang Denk, DENX Software Engineering, wd at denx.de.
+#
+# 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

board/eukrea/cpuat91/Makefile line 28

Quoted 10 lines
board/eukrea/cpuat91/Makefile new file +10 -0
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+# MA 02111-1307 USA
+#
+
+include $(TOPDIR)/config.mk
+
+LIB	= $(obj)lib$(BOARD).a
+
+COBJS	:= cpuat91.o

please be consistant with your other patch
$(BOARD)

Quoted 21 lines
board/eukrea/cpuat91/Makefile new file +21 -0
+
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
+OBJS	:= $(addprefix $(obj),$(COBJS))
+SOBJS	:= $(addprefix $(obj),$(SOBJS))
+
+$(LIB):	$(obj).depend $(OBJS) $(SOBJS)
+	$(AR) $(ARFLAGS) $@ $(OBJS) $(SOBJS)
+
+clean:
+	rm -f $(SOBJS) $(OBJS)
+
+distclean:	clean
+	rm -f $(LIB) core *.bak .depend
+
+#########################################################################
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+

<snip>

Quoted 12 lines
board/eukrea/cpuat91/Makefile new file +3 -0
+
+#endif	/* CONFIG_CMD_NET */
+#endif	/* CONFIG_DRIVER_ETHER */
cpu/arm920t/at91rm9200/Makefile +1 -0
index 73aeeac..114d8ad 100644
@@ -31,14 +31,15 @@ COBJS	+= bcm5221.o
 COBJS	+= dm9161.o
 COBJS	+= ether.o
 COBJS	+= i2c.o
+COBJS-$(CONFIG_KS8721_PHY)	+= ks8721.o

cpu/arm920t/at91rm9200/Makefile COBJS += bcm5221.o · line 42

Quoted 10 lines
cpu/arm920t/at91rm9200/Makefile +2 -2
 COBJS	+= lxt972.o
 COBJS	+= reset.o
 COBJS	+= spi.o
 COBJS	+= timer.o
 COBJS	+= usb.o
 
-SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
-OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS))
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS-y))

please switch all to COBJS-y

cpu/arm920t/at91rm9200/Makefile COBJS += bcm5221.o · line 45

Quoted 3 lines
cpu/arm920t/at91rm9200/Makefile +0 -0
 all:	$(obj).depend $(LIB)
 

you have also some whitespace in your patch please fix

Best Regards,
J.

#8 lore raw

PATCH v3 1/1 Add support for Eukrea CPUAT91 SBC

Dear Jean-Christophe PLAGNIOL-VILLARD,

Quoted 7 lines · In message <[email protected]> you wrote:
Quoted 7 lines
Makefile +0 -0
@@ -2683,6 +2683,18 @@ at91rm9200ek_config	:	unconfig
 cmc_pu2_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t cmc_pu2 NULL at91rm9200
 
Quoted 10 lines

Makefile at91rm9200ek_config : unconfig · line 2690

Quoted 5 lines
Makefile +5 -0
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@mkdir -p $(obj)include
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_CPUAT91_RAM 1" >>$(obj)include/config.h ; \

same as other patch
no need please define the
#define CONFIG_SKIP_LOWLEVEL_INIT
#define CONFIG_SKIP_RELOCATE_UBOOT
here

No. Not here, i. e. not in the Makefile. We don't want tens of lines of scripts per board in the top level Makefile.

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
When you die, the first thing you lose is your life. The  next  thing
is the illusions.                       - Terry Pratchett, _Pyramids_
#9 lore raw

PATCH v3 1/1 Add support for Eukrea CPUAT91 SBC

Quoted 21 lines · Wolfgang Denk

Dear Jean-Christophe PLAGNIOL-VILLARD,

Quoted 7 lines · In message <[email protected]> you wrote:
Quoted 7 lines
Makefile +0 -0
@@ -2683,6 +2683,18 @@ at91rm9200ek_config	:	unconfig
 cmc_pu2_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t cmc_pu2 NULL at91rm9200
 
Quoted 10 lines

Makefile at91rm9200ek_config : unconfig · line 2690

Quoted 5 lines
Makefile +5 -0
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@mkdir -p $(obj)include
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_CPUAT91_RAM 1" >>$(obj)include/config.h ; \

same as other patch
no need please define the
#define CONFIG_SKIP_LOWLEVEL_INIT
#define CONFIG_SKIP_RELOCATE_UBOOT
here

Quoted 2 lines

No. Not here, i. e. not in the Makefile. We don't want tens of lines of scripts per board in the top level Makefile.

I still do not want to see a new board specific config for this specially when we do have already config for this

Best Regards,
J.

#10 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

In reply to Jean-Christophe PLAGNIOL-VILLARD
Quoted 22 lines
Quoted 14 lines
cpu/arm920t/at91rm9200/Makefile +2 -2
-SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
-OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS))
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS-y))
 
 all:	$(obj).depend $(LIB)
cpu/arm920t/at91rm9200/ks8721.c new file +0 -0
new file mode 100644
index 0000000..703e58c

cpu/arm920t/at91rm9200/ks8721.c line 6

Quoted 6 lines
cpu/arm920t/at91rm9200/ks8721.c new file +6 -0
@@ -0,0 +1,244 @@
+/*
+ * (C) Copyright 2006
+ * Author : Eric Benard (Eukrea Electromatique)
+ * based on dm9161.c which is :
+ * (C) Copyright 2003
+ * Author : Hamid Ikdoumi (Atmel)

I'm not a fan of this implementation at all

Quoted 3 lines

but as I've not yet finish the rm9200 cleanup
I'll ack this ben what do you think?
ben please note that the rm9200 cleanup will introduce a phylib support

Ben ping

Best Regards,
J.

#11 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

Quoted 23 lines · Jean-Christophe PLAGNIOL-VILLARD
Quoted 23 lines
Quoted 15 lines
cpu/arm920t/at91rm9200/Makefile +2 -2
-SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
-OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS))
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS-y))
 
 all:	$(obj).depend $(LIB)
cpu/arm920t/at91rm9200/ks8721.c new file +0 -0
new file mode 100644
index 0000000..703e58c

cpu/arm920t/at91rm9200/ks8721.c line 6

Quoted 6 lines
cpu/arm920t/at91rm9200/ks8721.c new file +6 -0
@@ -0,0 +1,244 @@
+/*
+ * (C) Copyright 2006
+ * Author : Eric Benard (Eukrea Electromatique)
+ * based on dm9161.c which is :
+ * (C) Copyright 2003
+ * Author : Hamid Ikdoumi (Atmel)

I'm not a fan of this implementation at all

Quoted 9 lines
Quoted 4 lines

but as I've not yet finish the rm9200 cleanup
I'll ack this ben what do you think?
ben please note that the rm9200 cleanup will introduce a phylib support

Ben ping

Best Regards,
J.

This patch has many coding style violations that haven't been addressed, so it can't go in. I"m not a fan of the piece-meal PHY implementation either, but realize that a real PHY lib isn't imminent, unless your rm2000 implementation is useful across architectures.

regards,
Ben

#12 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

Quoted 2 lines · Ben Warren

This patch has many coding style violations that haven't been addressed, so it can't go in. I"m not a fan of the piece-meal PHY implementation

coding style violations should be fixed in v3 /
http://www.mail-archive.com/u-boot at lists.denx.de/msg18068.html

Eric

#13 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

Quoted 9 lines · Eric B?nard
Quoted 3 lines · Ben Warren

This patch has many coding style violations that haven't been addressed, so it can't go in. I"m not a fan of the piece-meal PHY implementation

coding style violations should be fixed in v3 /
http://www.mail-archive.com/u-boot at lists.denx.de/msg18068.html

Eric

Not quite. Camel-case function names like 'ks8721_IsPhyConnected' violate the coding style.
regards,
Ben

#14 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

CPUAT91 is built around Atmel's AT91RM9200 and has up to 16MB of NOR flash, up to 128MB of SDRAM, and includes a Micrel KS8721 PHY in RMII mode.

v3 : fix coding style issues
v4 : fix coding style in ks8721

---
 MAINTAINERS                     |    4 +
 MAKEALL                         |    3 +-
 Makefile                        |   12 ++
 board/eukrea/cpuat91/Makefile   |   50 ++++++++
 board/eukrea/cpuat91/config.mk  |    1 +
 board/eukrea/cpuat91/cpuat91.c  |   86 ++++++++++++++
 cpu/arm920t/at91rm9200/Makefile |    5 +-
 cpu/arm920t/at91rm9200/ks8721.c |  242 +++++++++++++++++++++++++++++++++++++++
 include/configs/cpuat91.h       |  231 +++++++++++++++++++++++++++++++++++++
 include/ks8721.h                |   78 +++++++++++++
 10 files changed, 709 insertions(+), 3 deletions(-)
 create mode 100644 board/eukrea/cpuat91/Makefile
 create mode 100644 board/eukrea/cpuat91/config.mk
 create mode 100644 board/eukrea/cpuat91/cpuat91.c
 create mode 100644 cpu/arm920t/at91rm9200/ks8721.c
 create mode 100644 include/configs/cpuat91.h
 create mode 100644 include/ks8721.h
MAINTAINERS +4 -0
index 620604c..e45a5ef 100644
@@ -521,6 +521,10 @@ Dirk Behme <[email protected]>
 
 	omap3_beagle	ARM CORTEX-A8 (OMAP3530 SoC)
 
+Eric Benard <[email protected]>
+
+	cpuat91		ARM920T
+
 Rishi Bhattacharya <[email protected]>
 
 	omap5912osk	ARM926EJS
MAKEALL +2 -1
index dd0b761..6d18e7f 100755
@@ -595,11 +595,12 @@ LIST_at91="			\
 	at91sam9260ek		\
 	at91sam9261ek		\
 	at91sam9263ek		\
-	at91sam9g10ek	\
+	at91sam9g10ek		\
 	at91sam9g20ek		\
 	at91sam9m10g45ek	\
 	at91sam9rlek		\
 	cmc_pu2			\
+	cpuat91			\
 	csb637			\
 	kb9202			\
 	meesc			\
Makefile +12 -0
index ac844a7..655cb03 100644
@@ -2673,6 +2673,18 @@ at91rm9200ek_config	:	unconfig
 cmc_pu2_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t cmc_pu2 NULL at91rm9200
 
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@mkdir -p $(obj)include
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_CPUAT91_RAM 1" >>$(obj)include/config.h ; \
+		$(XECHO) "... CPUAT91 configured for RAM" ; \
+	else \
+		echo "#define CONFIG_BOOTDELAY 1" >>$(obj)include/config.h ;\
+		$(XECHO) "... CPUAT91 configured for Flash" ;\
+	fi;
+	@$(MKCONFIG) -a cpuat91 arm arm920t cpuat91 eukrea at91rm9200
+
 csb637_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t csb637 NULL at91rm9200
 
board/eukrea/cpuat91/Makefile new file +50 -0

50 lines not on this page · raw message

board/eukrea/cpuat91/config.mk new file +1 -0
new file mode 100644
index 0000000..ef8dda0
@@ -0,0 +1 @@
+TEXT_BASE = 0x21F00000
board/eukrea/cpuat91/cpuat91.c new file +86 -0

86 lines not on this page · raw message

cpu/arm920t/at91rm9200/Makefile +3 -2
index 73aeeac..114d8ad 100644
@@ -31,14 +31,15 @@ COBJS	+= bcm5221.o
 COBJS	+= dm9161.o
 COBJS	+= ether.o
 COBJS	+= i2c.o
+COBJS-$(CONFIG_KS8721_PHY)	+= ks8721.o
 COBJS	+= lxt972.o
 COBJS	+= reset.o
 COBJS	+= spi.o
 COBJS	+= timer.o
 COBJS	+= usb.o
 
-SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
-OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS))
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS-y))
 
 all:	$(obj).depend $(LIB)
 
cpu/arm920t/at91rm9200/ks8721.c new file +242 -0

242 lines not on this page · raw message

include/configs/cpuat91.h new file +231 -0

231 lines not on this page · raw message

include/ks8721.h new file +78 -0

78 lines not on this page · raw message

Signature · 1 line
1.6.0.4
#15 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

MAKEALL LIST_at91=" \ · line 598

Quoted 9 lines

index dd0b761..6d18e7f 100755

MAKEALL +1 -1
@@ -595,11 +595,12 @@ LIST_at91="			\
 	at91sam9260ek		\
 	at91sam9261ek		\
 	at91sam9263ek		\
-	at91sam9g10ek	\
+	at91sam9g10ek		\

again please do this in an other patch

Quoted 13 lines
MAKEALL +1 -0
 	at91sam9g20ek		\
 	at91sam9m10g45ek	\
 	at91sam9rlek		\
 	cmc_pu2			\
+	cpuat91			\
 	csb637			\
 	kb9202			\
 	meesc			\
Makefile +0 -0
index ac844a7..655cb03 100644

Makefile at91rm9200ek_config : unconfig · line 2680

Quoted 8 lines
Makefile +5 -0
@@ -2673,6 +2673,18 @@ at91rm9200ek_config	:	unconfig
 cmc_pu2_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t cmc_pu2 NULL at91rm9200
 
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@mkdir -p $(obj)include
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_CPUAT91_RAM 1" >>$(obj)include/config.h ; \

NACK
no new config for this you must use the current one

Makefile at91rm9200ek_config : unconfig · line 2690

Quoted 10 lines
Makefile +7 -0
+		$(XECHO) "... CPUAT91 configured for RAM" ; \
+	else \
+		echo "#define CONFIG_BOOTDELAY 1" >>$(obj)include/config.h ;\
+		$(XECHO) "... CPUAT91 configured for Flash" ;\
+	fi;
+	@$(MKCONFIG) -a cpuat91 arm arm920t cpuat91 eukrea at91rm9200
+
 csb637_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t csb637 NULL at91rm9200
 

<nip>

Quoted 7 lines
Makefile +7 -0
+
+#ifndef __CONFIG_H
+#define __CONFIG_H
+
+#if defined(CONFIG_CPUAT91_RAM)
+#define CONFIG_SKIP_LOWLEVEL_INIT	1
+#define CONFIG_SKIP_RELOCATE_UBOOT	1

Makefile

Quoted 10 lines
Makefile +10 -0
+#endif
+
+#define AT91C_MAIN_CLOCK		179712000
+#define AT91C_MASTER_CLOCK		59904000
+
+#define AT91_SLOW_CLOCK			32768
+
+#define CONFIG_ARM920T			1
+#define CONFIG_AT91RM9200		1
+#define CONFIG_AT91RM9200DK		1

you are not a DK
please fix it

Quoted 41 lines
Makefile +41 -0
+#define CONFIG_CPUAT91			1
+
+#undef CONFIG_USE_IRQ
+#define USE_920T_MMU			1
+
+#define CONFIG_CMDLINE_TAG		1
+#define CONFIG_SETUP_MEMORY_TAGS	1
+#define CONFIG_INITRD_TAG		1
+
+#ifndef CONFIG_SKIP_LOWLEVEL_INIT
+#define CONFIG_SYS_USE_MAIN_OSCILLATOR	1
+/* flash */
+#define CONFIG_SYS_MC_PUIA_VAL	0x00000000
+#define CONFIG_SYS_MC_PUP_VAL	0x00000000
+#define CONFIG_SYS_MC_PUER_VAL	0x00000000
+#define CONFIG_SYS_MC_ASR_VAL	0x00000000
+#define CONFIG_SYS_MC_AASR_VAL	0x00000000
+#define CONFIG_SYS_EBI_CFGR_VAL	0x00000000
+#define CONFIG_SYS_SMC_CSR0_VAL	0x00003284 /* 16bit, 2 TDF, 4 WS */
+
+/* clocks */
+#define CONFIG_SYS_PLLAR_VAL	0x20263E04 /* 179.712000 MHz for PCK */
+#define CONFIG_SYS_PLLBR_VAL	0x10483E0E /* 48.054857 MHz for USB */
+#define CONFIG_SYS_MCKR_VAL	0x00000202 /* PCK/3 = MCK Master Clock */
+
+/* sdram */
+#define CONFIG_SYS_PIOC_ASR_VAL	0xFFFF0000 /* Configure PIOC as D16/D31 */
+#define CONFIG_SYS_PIOC_BSR_VAL	0x00000000
+#define CONFIG_SYS_PIOC_PDR_VAL	0xFFFF0000
+#define CONFIG_SYS_EBI_CSA_VAL	0x00000002 /* CS1=SDRAM */
+#define CONFIG_SYS_SDRC_CR_VAL	0x2188C155 /* set up the SDRAM */
+#define CONFIG_SYS_SDRAM	0x20000000 /* address of the SDRAM */
+#define CONFIG_SYS_SDRAM1	0x20000080 /* address of the SDRAM */
+#define CONFIG_SYS_SDRAM_VAL	0x00000000 /* value written to SDRAM */
+#define CONFIG_SYS_SDRC_MR_VAL	0x00000002 /* Precharge All */
+#define CONFIG_SYS_SDRC_MR_VAL1	0x00000004 /* refresh */
+#define CONFIG_SYS_SDRC_MR_VAL2	0x00000003 /* Load Mode Register */
+#define CONFIG_SYS_SDRC_MR_VAL3	0x00000000 /* Normal Mode */
+#define CONFIG_SYS_SDRC_TR_VAL	0x000002E0 /* Write refresh rate */
+#endif	/* CONFIG_SKIP_LOWLEVEL_INIT */
+

Makefile

Quoted 10 lines
Makefile +8 -0
+/* define one of these to choose the DBGU, USART0 or USART1 as console */
+#define CONFIG_AT91RM9200_USART		1
+#define CONFIG_DBGU			1
+#undef CONFIG_USART0
+#undef CONFIG_USART1
+
 
 
+#undef CONFIG_HWFLOW
+#undef CONFIG_MODEM_SUPPORT

no need please remove

Quoted 19 lines
Makefile +19 -0
+
+#define CONFIG_HARD_I2C			1
+
+#if defined(CONFIG_HARD_I2C)
+#define	CONFIG_SYS_I2C_SPEED			50000
+#define CONFIG_SYS_I2C_SLAVE			0
+#define CONFIG_SYS_I2C_EEPROM_ADDR		0x54
+#define CONFIG_SYS_I2C_EEPROM_ADDR_LEN		1
+#define CONFIG_SYS_I2C_EEPROM_ADDR_OVERFLOW	1
+#define	CONFIG_SYS_EEPROM_PAGE_WRITE_DELAY_MS	10
+#endif
+
+#define CONFIG_BOOTP_BOOTFILESIZE	1
+#define CONFIG_BOOTP_BOOTPATH		1
+#define CONFIG_BOOTP_GATEWAY		1
+#define CONFIG_BOOTP_HOSTNAME		1
+
+#include <config_cmd_default.h>
+

Makefile

Quoted 10 lines
Makefile +10 -0
+#define CONFIG_CMD_DHCP			1
+#define CONFIG_CMD_PING			1
+#define CONFIG_CMD_MII			1
+#define CONFIG_CMD_CACHE		1
+#undef CONFIG_CMD_USB
+
+#undef CONFIG_CMD_FPGA
+#undef CONFIG_CMD_IMI
+#undef CONFIG_CMD_LOADS
+#undef CONFIG_CMD_NFS

please fix the whitespace too

Best Regards,
J.

#16 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

Hi Jean-Christophe,

Jean-Christophe PLAGNIOL-VILLARD a ?crit :

Quoted 7 lines

Makefile at91rm9200ek_config : unconfig · line 2680

Quoted 5 lines
Makefile +5 -0
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@mkdir -p $(obj)include
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_CPUAT91_RAM 1" >>$(obj)include/config.h ; \

NACK
no new config for this you must use the current one

You told me :
"no need please define the
#define CONFIG_SKIP_LOWLEVEL_INIT
#define CONFIG_SKIP_RELOCATE_UBOOT
here"
Wolfgang said :
"No. Not here, i. e. not in the Makefile. We don't want tens of lines of scripts per board in the top level Makefile."

So may you please give me a hint of what is the right way to do this ?

Quoted 7 lines

Makefile at91rm9200ek_config : unconfig · line 2687

Quoted 7 lines
Makefile +7 -0
+		$(XECHO) "... CPUAT91 configured for RAM" ; \
+	else \
+		echo "#define CONFIG_BOOTDELAY 1" >>$(obj)include/config.h ;\
+		$(XECHO) "... CPUAT91 configured for Flash" ;\
+	fi;
+	@$(MKCONFIG) -a cpuat91 arm arm920t cpuat91 eukrea at91rm9200
+

Thanks
Eric

#17 lore raw

PATCH v5 1/1 Add support for Eukrea CPUAT91 SBC

In reply to Jean-Christophe PLAGNIOL-VILLARD

CPUAT91 is built around Atmel's AT91RM9200 and has up to 16MB of NOR flash, up to 128MB of SDRAM, and includes a Micrel KS8721 PHY in RMII mode.

v3 : fix coding style issues
v4 : fix coding style in ks8721
v5 : fix following Jean Christophe's review

---
 MAINTAINERS                     |    4 +
 MAKEALL                         |    1 +
 Makefile                        |   13 ++
 board/eukrea/cpuat91/Makefile   |   50 ++++++++
 board/eukrea/cpuat91/config.mk  |    1 +
 board/eukrea/cpuat91/cpuat91.c  |   86 ++++++++++++++
 cpu/arm920t/at91rm9200/Makefile |    5 +-
 cpu/arm920t/at91rm9200/ks8721.c |  242 +++++++++++++++++++++++++++++++++++++++
 include/configs/cpuat91.h       |  226 ++++++++++++++++++++++++++++++++++++
 include/ks8721.h                |   78 +++++++++++++
 10 files changed, 704 insertions(+), 2 deletions(-)
 create mode 100644 board/eukrea/cpuat91/Makefile
 create mode 100644 board/eukrea/cpuat91/config.mk
 create mode 100644 board/eukrea/cpuat91/cpuat91.c
 create mode 100644 cpu/arm920t/at91rm9200/ks8721.c
 create mode 100644 include/configs/cpuat91.h
 create mode 100644 include/ks8721.h
MAINTAINERS +4 -0
index 620604c..e45a5ef 100644
@@ -521,6 +521,10 @@ Dirk Behme <[email protected]>
 
 	omap3_beagle	ARM CORTEX-A8 (OMAP3530 SoC)
 
+Eric Benard <[email protected]>
+
+	cpuat91		ARM920T
+
 Rishi Bhattacharya <[email protected]>
 
 	omap5912osk	ARM926EJS
MAKEALL +1 -0
index edebaea..97a29f2 100755
@@ -600,6 +600,7 @@ LIST_at91="			\
 	at91sam9m10g45ek	\
 	at91sam9rlek		\
 	cmc_pu2			\
+	cpuat91			\
 	csb637			\
 	kb9202			\
 	meesc			\
Makefile +13 -0
index 54c0b67..2386cdc 100644
@@ -2674,6 +2674,19 @@ at91rm9200ek_config	:	unconfig
 cmc_pu2_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t cmc_pu2 NULL at91rm9200
 
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@mkdir -p $(obj)include
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_SKIP_LOWLEVEL_INIT" >> $(obj)include/config.h; \
+		echo "#define CONFIG_SKIP_RELOCATE_UBOOT" >> $(obj)include/config.h; \
+		$(XECHO) "... CPUAT91 configured for RAM" ; \
+	else \
+		echo "#define CONFIG_BOOTDELAY 1" >>$(obj)include/config.h ; \
+		$(XECHO) "... CPUAT91 configured for Flash" ;\
+	fi;
+	@$(MKCONFIG) -a cpuat91 arm arm920t cpuat91 eukrea at91rm9200
+
 csb637_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t csb637 NULL at91rm9200
 
board/eukrea/cpuat91/Makefile new file +50 -0

50 lines not on this page · raw message

board/eukrea/cpuat91/config.mk new file +1 -0
new file mode 100644
index 0000000..ef8dda0
@@ -0,0 +1 @@
+TEXT_BASE = 0x21F00000
board/eukrea/cpuat91/cpuat91.c new file +86 -0

86 lines not on this page · raw message

cpu/arm920t/at91rm9200/Makefile +3 -2
index 73aeeac..114d8ad 100644
@@ -31,14 +31,15 @@ COBJS	+= bcm5221.o
 COBJS	+= dm9161.o
 COBJS	+= ether.o
 COBJS	+= i2c.o
+COBJS-$(CONFIG_KS8721_PHY)	+= ks8721.o
 COBJS	+= lxt972.o
 COBJS	+= reset.o
 COBJS	+= spi.o
 COBJS	+= timer.o
 COBJS	+= usb.o
 
-SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
-OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS))
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS-y))
 
 all:	$(obj).depend $(LIB)
 
cpu/arm920t/at91rm9200/ks8721.c new file +242 -0

242 lines not on this page · raw message

include/configs/cpuat91.h new file +226 -0

226 lines not on this page · raw message

include/ks8721.h new file +78 -0

78 lines not on this page · raw message

Signature · 1 line
1.6.0.4
#18 lore raw

PATCH v5 1/1 Add support for Eukrea CPUAT91 SBC

Quoted 7 lines · Eric Benard

CPUAT91 is built around Atmel's AT91RM9200 and has up to 16MB of NOR flash, up to 128MB of SDRAM, and includes a Micrel KS8721 PHY in RMII mode.

v3 : fix coding style issues
v4 : fix coding style in ks8721
v5 : fix following Jean Christophe's review

please this here version information

Quoted 3 lines

---

here next time

Quoted 9 lines
 MAINTAINERS                     |    4 +
 MAKEALL                         |    1 +
 Makefile                        |   13 ++
 board/eukrea/cpuat91/Makefile   |   50 ++++++++
 board/eukrea/cpuat91/config.mk  |    1 +
 board/eukrea/cpuat91/cpuat91.c  |   86 ++++++++++++++
 cpu/arm920t/at91rm9200/Makefile |    5 +-
 cpu/arm920t/at91rm9200/ks8721.c |  242 +++++++++++++++++++++++++++++++++++++++
 include/configs/cpuat91.h       |  226 ++++++++++++++++++++++++++++++++++++
Quoted 9 lines
 include/ks8721.h                |   78 +++++++++++++
 10 files changed, 704 insertions(+), 2 deletions(-)
 create mode 100644 board/eukrea/cpuat91/Makefile
 create mode 100644 board/eukrea/cpuat91/config.mk
 create mode 100644 board/eukrea/cpuat91/cpuat91.c
 create mode 100644 cpu/arm920t/at91rm9200/ks8721.c
 create mode 100644 include/configs/cpuat91.h
 create mode 100644 include/ks8721.h

Ben is also it ok for you this patch?

Best Regards,
J.

#19 lore raw

PATCH v5 1/1 Add support for Eukrea CPUAT91 SBC

In reply to Eric Benard

Dear Eric Benard,

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

CPUAT91 is built around Atmel's AT91RM9200 and has up to 16MB of NOR flash, up to 128MB of SDRAM, and includes a Micrel KS8721 PHY in RMII mode.

...

Quoted 5 lines
Makefile +5 -0
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@mkdir -p $(obj)include
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_SKIP_LOWLEVEL_INIT" >> $(obj)include/config.h; \

Makefile at91rm9200ek_config : unconfig · line 2691

Quoted 10 lines
Makefile +8 -0
+		echo "#define CONFIG_SKIP_RELOCATE_UBOOT" >> $(obj)include/config.h; \
+		$(XECHO) "... CPUAT91 configured for RAM" ; \
+	else \
+		echo "#define CONFIG_BOOTDELAY 1" >>$(obj)include/config.h ; \
+		$(XECHO) "... CPUAT91 configured for Flash" ;\
+	fi;
+	@$(MKCONFIG) -a cpuat91 arm arm920t cpuat91 eukrea at91rm9200
+
 csb637_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t csb637 NULL at91rm9200

Please do not add such scripting to the top level Makefile. Perform it in your board config file instead.

For an example, please see
http://thread.gmane.org/gmane.comp.boot-loaders.u-boot/65499

Quoted 2 lines
cpu/arm920t/at91rm9200/ks8721.c new file +2 -0
+unsigned char ks8721_autonegotiate(AT91PS_EMAC p_mac, int *status)
+{

...

cpu/arm920t/at91rm9200/ks8721.c line 189

Quoted 3 lines
cpu/arm920t/at91rm9200/ks8721.c new file +3 -0
+	/* Set the Auto_negotiation Advertisement Register */
+	/* MII advertising for Next page, 100BaseTxFD and HD, */
+	/* 10BaseTFD and HD, IEEE 802.3 */

Incorrect multiline comment style.

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
Madness has no purpose.  Or reason.  But it may have a goal.
	-- Spock, "The Alternative Factor", stardate 3088.7
#20 lore raw

PATCH v5 1/1 Add support for Eukrea CPUAT91 SBC

In reply to Eric Benard

Dear Eric Benard,

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

CPUAT91 is built around Atmel's AT91RM9200 and has up to 16MB of NOR flash, up to 128MB of SDRAM, and includes a Micrel KS8721 PHY in RMII mode.

...

Quoted 14 lines
(quoted diff) +0 -0
 	meesc			\
Makefile +5 -0
index 54c0b67..2386cdc 100644
@@ -2674,6 +2674,19 @@ at91rm9200ek_config	:	unconfig
 cmc_pu2_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t cmc_pu2 NULL at91rm9200
 
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@mkdir -p $(obj)include
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_SKIP_LOWLEVEL_INIT" >> $(obj)include/config.h; \

Makefile at91rm9200ek_config : unconfig · line 2691

Quoted 10 lines
Makefile +8 -0
+		echo "#define CONFIG_SKIP_RELOCATE_UBOOT" >> $(obj)include/config.h; \
+		$(XECHO) "... CPUAT91 configured for RAM" ; \
+	else \
+		echo "#define CONFIG_BOOTDELAY 1" >>$(obj)include/config.h ; \
+		$(XECHO) "... CPUAT91 configured for Flash" ;\
+	fi;
+	@$(MKCONFIG) -a cpuat91 arm arm920t cpuat91 eukrea at91rm9200
+
 csb637_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t csb637 NULL at91rm9200

Please do not add such scripting to the top level Makefile. Perform it in your board config file instead.

For an example, please see
http://thread.gmane.org/gmane.comp.boot-loaders.u-boot/65499

...

Makefile at91rm9200ek_config : unconfig

Quoted 8 lines
Makefile +8 -0
+int board_init(void)
+{
+	/* Enable Ctrlc */
+	console_init_f();
+
+	/* memory and cpu-speed are setup before relocation
+	 * so we do _nothing_ here
+	 */

Incorrect multicomment style.

Makefile

Quoted 11 lines
Makefile +11 -0
+unsigned char ks8721_initphy(AT91PS_EMAC p_mac)
+{
+	unsigned char ret = 1;
+	unsigned short intvalue;
+
+	at91rm9200_EmacEnableMDIO(p_mac);
+
+	if (!ks8721_getlinkspeed(p_mac)) {
+		/* Try another time */
+		ret = ks8721_getlinkspeed(p_mac);
+	}

Move comment up into the "if" line, and remove the braces for a single-line statement.

...

Makefile

Quoted 10 lines
Makefile +10 -0
+unsigned char ks8721_autonegotiate(AT91PS_EMAC p_mac, int *status)
+{
+	unsigned short value;
+	unsigned short phyanar;
+	unsigned short phyanalpar;
+
+	/* Set ks8721 control register */
+	if (!at91rm9200_EmacReadPhy(p_mac,
+		CONFIG_PHY_ADDRESS | KS8721_BMCR, &value))
+		return 0;

Here and everywhere else: please add braces around multiline statements.

Makefile

Quoted 9 lines
Makefile +9 -0
+	value &= ~KS8721_AUTONEG;	/* remove autonegotiation enable */
+	value |= KS8721_ISOLATE;	/* Electrically isolate PHY */
+	if (!at91rm9200_EmacWritePhy(p_mac,
+		CONFIG_PHY_ADDRESS | KS8721_BMCR, &value))
+		return 0;
+
+	/* Set the Auto_negotiation Advertisement Register */
+	/* MII advertising for Next page, 100BaseTxFD and HD, */
+	/* 10BaseTFD and HD, IEEE 802.3 */

Incorrect multiline comment style.

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
"Do we define evil as the absence of goodness? It seems only  logical
that shit happens--we discover this by the process of elimination."
                                                        -- Larry Wall
#21 lore raw

PATCH v5 1/1 Add support for Eukrea CPUAT91 SBC

Dear Wolfgang,

Quoted 26 lines · Wolfgang Denk

Dear Eric Benard,

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

CPUAT91 is built around Atmel's AT91RM9200 and has up to 16MB of NOR flash, up to 128MB of SDRAM, and includes a Micrel KS8721 PHY in RMII mode.

...

Quoted 19 lines
(quoted diff) +0 -0
 	meesc			\
Makefile +10 -0
index 54c0b67..2386cdc 100644
@@ -2674,6 +2674,19 @@ at91rm9200ek_config	:	unconfig
 cmc_pu2_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t cmc_pu2 NULL at91rm9200
 
+cpuat91_ram_config \
+cpuat91_config	:	unconfig
+	@mkdir -p $(obj)include
+	@if [ "$(findstring _ram_,$@)" ] ; then \
+		echo "#define CONFIG_SKIP_LOWLEVEL_INIT" >> $(obj)include/config.h; \
+		echo "#define CONFIG_SKIP_RELOCATE_UBOOT" >> $(obj)include/config.h; \
+		$(XECHO) "... CPUAT91 configured for RAM" ; \
+	else \
+		echo "#define CONFIG_BOOTDELAY 1" >>$(obj)include/config.h ; \
+		$(XECHO) "... CPUAT91 configured for Flash" ;\
Quoted 8 lines

Makefile at91rm9200ek_config : unconfig · line 2691

Quoted 5 lines
Makefile +3 -0
+	fi;
+	@$(MKCONFIG) -a cpuat91 arm arm920t cpuat91 eukrea at91rm9200
+
 csb637_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t csb637 NULL at91rm9200

Please do not add such scripting to the top level Makefile. Perform it in your board config file instead.

Not sure if this is 'standard' for at91, but I saw something similar in

http://git.denx.de/?p=u-boot/u-boot-arm.git;a=blobdiff;f=Makefile;h=c9d315ae98f2272659b88405cd2b94265f3bbfc3;hp=54c0b67499510f83fa642b9684ad95ce832de1b9;hb=f8ea12cf9be98508096dc4102a6ef40cb484fdd3;hpb=c6b5600aee06a13e556837c3065f7f8721d56ec9

Best regards

Dirk

#22 lore raw

PATCH v5 1/1 Add support for Eukrea CPUAT91 SBC

Dear Dirk Behme,

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

Please do not add such scripting to the top level Makefile. Perform it in your board config file instead.

Not sure if this is 'standard' for at91, but I saw something similar in

http://git.denx.de/?p=u-boot/u-boot-arm.git;a=blobdiff;f=Makefile;h=c9d315ae98f2272659b88405cd2b94265f3bbfc3;hp=54c0b67499510f83fa642b9684ad95ce832de1b9;hb=f8ea12cf9be98508096dc4102a6ef40cb484fdd3;hpb=c6b5600aee06a13e556837c3065f7f8721d56ec9

Yes, I know. This has been accepted and even pretty usual style for a long time - too long, actually.

The Makefile has grown way too long. Sometimes it takes a long time until we learn a lesson. Now I want to get rid of most of such longish scripting in the Makefile, and I started rejecting all patches that add such stuff.

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
They're usually so busy thinking about what  happens  next  that  the
only  time they ever find out what is happening now is when they come
to look back on it.                 - Terry Pratchett, _Wyrd Sisters_
#23 lore raw

PATCH v6 1/1 Add support for Eukrea CPUAT91 SBC

In reply to Wolfgang Denk

CPUAT91 is built around Atmel's AT91RM9200 and has up to 16MB of NOR flash, up to 128MB of SDRAM, and includes a Micrel KS8721 PHY in RMII mode.

---
v3 : fix coding style issues
v4 : fix coding style in ks8721
v5 : fix following Jean Christophe's review
v6 : fix following Wolfgang Denx's review

 MAINTAINERS                     |    4 +
 MAKEALL                         |    3 +-
 Makefile                        |    6 +
 board/eukrea/cpuat91/Makefile   |   50 ++++++++
 board/eukrea/cpuat91/config.mk  |    1 +
 board/eukrea/cpuat91/cpuat91.c  |   81 +++++++++++++
 cpu/arm920t/at91rm9200/Makefile |    5 +-
 cpu/arm920t/at91rm9200/ks8721.c |  249 +++++++++++++++++++++++++++++++++++++++
 include/configs/cpuat91.h       |  228 +++++++++++++++++++++++++++++++++++
 include/ks8721.h                |   78 ++++++++++++
 10 files changed, 702 insertions(+), 3 deletions(-)
 create mode 100644 board/eukrea/cpuat91/Makefile
 create mode 100644 board/eukrea/cpuat91/config.mk
 create mode 100644 board/eukrea/cpuat91/cpuat91.c
 create mode 100644 cpu/arm920t/at91rm9200/ks8721.c
 create mode 100644 include/configs/cpuat91.h
 create mode 100644 include/ks8721.h
MAINTAINERS +4 -0
index 620604c..e45a5ef 100644
@@ -521,6 +521,10 @@ Dirk Behme <[email protected]>
 
 	omap3_beagle	ARM CORTEX-A8 (OMAP3530 SoC)
 
+Eric Benard <[email protected]>
+
+	cpuat91		ARM920T
+
 Rishi Bhattacharya <[email protected]>
 
 	omap5912osk	ARM926EJS
MAKEALL +2 -1
index edebaea..abed691 100755
@@ -595,11 +595,12 @@ LIST_at91="			\
 	at91sam9260ek		\
 	at91sam9261ek		\
 	at91sam9263ek		\
-	at91sam9g10ek	\
+	at91sam9g10ek		\
 	at91sam9g20ek		\
 	at91sam9m10g45ek	\
 	at91sam9rlek		\
 	cmc_pu2			\
+	CPUAT91			\
 	csb637			\
 	kb9202			\
 	meesc			\
Makefile +6 -0
index 54c0b67..8d716ed 100644
@@ -2674,6 +2674,12 @@ at91rm9200ek_config	:	unconfig
 cmc_pu2_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t cmc_pu2 NULL at91rm9200
 
+CPUAT91_RAM_config \
+CPUAT91_config	:	unconfig
+	@mkdir -p $(obj)include
+	@echo "#define CONFIG_$(@:_config=) 1"	>$(obj)include/config.h
+	@$(MKCONFIG) -a cpuat91 arm arm920t cpuat91 eukrea at91rm9200
+
 csb637_config	:	unconfig
 	@$(MKCONFIG) $(@:_config=) arm arm920t csb637 NULL at91rm9200
 
board/eukrea/cpuat91/Makefile new file +50 -0

50 lines not on this page · raw message

board/eukrea/cpuat91/config.mk new file +1 -0
new file mode 100644
index 0000000..ef8dda0
@@ -0,0 +1 @@
+TEXT_BASE = 0x21F00000
board/eukrea/cpuat91/cpuat91.c new file +81 -0

81 lines not on this page · raw message

cpu/arm920t/at91rm9200/Makefile +3 -2
index 73aeeac..114d8ad 100644
@@ -31,14 +31,15 @@ COBJS	+= bcm5221.o
 COBJS	+= dm9161.o
 COBJS	+= ether.o
 COBJS	+= i2c.o
+COBJS-$(CONFIG_KS8721_PHY)	+= ks8721.o
 COBJS	+= lxt972.o
 COBJS	+= reset.o
 COBJS	+= spi.o
 COBJS	+= timer.o
 COBJS	+= usb.o
 
-SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
-OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS))
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS-y))
 
 all:	$(obj).depend $(LIB)
 
cpu/arm920t/at91rm9200/ks8721.c new file +249 -0

249 lines not on this page · raw message

include/configs/cpuat91.h new file +228 -0

228 lines not on this page · raw message

include/ks8721.h new file +78 -0

78 lines not on this page · raw message

Signature · 1 line
1.6.0.4
#24 lore raw

PATCH v5 1/1 Cosmetic fix in MAKEALL as a separate patch

In reply to Jean-Christophe PLAGNIOL-VILLARD
---
 MAKEALL |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
MAKEALL +1 -1
index 97a29f2..759ccc2 100755
@@ -595,7 +595,7 @@ LIST_at91="			\
 	at91sam9260ek		\
 	at91sam9261ek		\
 	at91sam9263ek		\
-	at91sam9g10ek	\
+	at91sam9g10ek		\
 	at91sam9g20ek		\
 	at91sam9m10g45ek	\
 	at91sam9rlek		\
Signature · 1 line
1.6.0.4
#25 lore raw

PATCH v5 1/1 Cosmetic fix in MAKEALL as a separate patch

Dear Eric Benard,

Quoted 4 lines · In message <[email protected]> you wrote:
---
 MAKEALL |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

This should be merged with the original patch when you resubmit it.

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
Artificial Intelligence is the study of how to  make  real  computers
act like the ones in movies.
#26 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

In reply to Ben Warren
Quoted 25 lines · Ben Warren
Quoted 24 lines · Jean-Christophe PLAGNIOL-VILLARD
Quoted 19 lines
Quoted 11 lines
cpu/arm920t/at91rm9200/Makefile +2 -2
-SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
-OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS))
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS-y))

all: $(obj).depend $(LIB)

cpu/arm920t/at91rm9200/ks8721.c new file +0 -0
new file mode 100644
index 0000000..703e58c

cpu/arm920t/at91rm9200/ks8721.c line 6

Quoted 6 lines
cpu/arm920t/at91rm9200/ks8721.c new file +6 -0
@@ -0,0 +1,244 @@
+/*
+ * (C) Copyright 2006
+ * Author : Eric Benard (Eukrea Electromatique)
+ * based on dm9161.c which is :
+ * (C) Copyright 2003
+ * Author : Hamid Ikdoumi (Atmel)

I'm not a fan of this implementation at all

Quoted 3 lines

but as I've not yet finish the rm9200 cleanup
I'll ack this ben what do you think?
ben please note that the rm9200 cleanup will introduce a phylib support

Ben ping

Quoted 7 lines
Quoted 2 lines

Best Regards,
J.

This patch has many coding style violations that haven't been addressed, so it can't go in. I"m not a fan of the piece-meal PHY implementation either, but realize that a real PHY lib isn't imminent, unless your rm2000 implementation is useful across architectures.

it will be a generic implementation
as we need it also for other soc and arch for our boards.

Best Regards,
J.

#27 lore raw

PATCH 1/1 Add support for Eukrea CPUAT91 SBC

Quoted 39 lines · Jean-Christophe PLAGNIOL-VILLARD
Quoted 28 lines · Ben Warren
Quoted 26 lines · Jean-Christophe PLAGNIOL-VILLARD
Quoted 20 lines
Quoted 12 lines
cpu/arm920t/at91rm9200/Makefile +2 -2
-SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c)
-OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS))
+SRCS	:= $(SOBJS:.o=.S) $(COBJS:.o=.c) $(COBJS-y:.o=.c)
+OBJS	:= $(addprefix $(obj),$(SOBJS) $(COBJS) $(COBJS-y))

all: $(obj).depend $(LIB)

cpu/arm920t/at91rm9200/ks8721.c new file +0 -0
new file mode 100644
index 0000000..703e58c

cpu/arm920t/at91rm9200/ks8721.c line 6

Quoted 6 lines
cpu/arm920t/at91rm9200/ks8721.c new file +6 -0
@@ -0,0 +1,244 @@
+/*
+ * (C) Copyright 2006
+ * Author : Eric Benard (Eukrea Electromatique)
+ * based on dm9161.c which is :
+ * (C) Copyright 2003
+ * Author : Hamid Ikdoumi (Atmel)

I'm not a fan of this implementation at all

Quoted 4 lines

but as I've not yet finish the rm9200 cleanup
I'll ack this ben what do you think?
ben please note that the rm9200 cleanup will introduce a phylib support

Ben ping

Quoted 9 lines
Quoted 3 lines

Best Regards,
J.

This patch has many coding style violations that haven't been addressed, so it can't go in. I"m not a fan of the piece-meal PHY implementation either, but realize that a real PHY lib isn't imminent, unless your rm2000 implementation is useful across architectures.

Quoted 6 lines

it will be a generic implementation
as we need it also for other soc and arch for our boards.

Best Regards,
J.

Good. Can't wait.

Ben