Re: [U-Boot] [PATCH] add support for EMK TOP7000 CPU Module (3rd try)

2010-06-07 Thread Reinhard Meyer (-VC)
Reinhard Meyer (-VC) schrieb:
> Add support for EMK TOP7000 CPU Module
> 
> Specifics:
> 
> 1) create subdir board/emk/top7000 and files in it
> 2) create include/configs/top7000.h
> 3) update board/emk/common/vpd.c
> 4) add call to misc_init_r() to arch/avr32/lib/board.c
> 5) create arch/avr32/include/asm/unaligned.h to
>fix zlib.c compilation problem
> 6) update Makefile, MAINTAINERS, MAKEALL
> 
> Signed-off-by: Reinhard Meyer 

Hi,

was this my patch overseen now? Its from 6.6.2010...

Reinhard

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH] add support for EMK TOP7000 CPU Module (3rd try)

2010-06-06 Thread Reinhard Meyer (-VC)
Add support for EMK TOP7000 CPU Module

Specifics:

1) create subdir board/emk/top7000 and files in it
2) create include/configs/top7000.h
3) update board/emk/common/vpd.c
4) add call to misc_init_r() to arch/avr32/lib/board.c
5) create arch/avr32/include/asm/unaligned.h to
   fix zlib.c compilation problem
6) update Makefile, MAINTAINERS, MAKEALL

Signed-off-by: Reinhard Meyer 

---
 MAINTAINERS|6 +-
 MAKEALL|1 +
 Makefile   |3 +
 arch/avr32/include/asm/unaligned.h |1 +
 arch/avr32/lib/board.c |5 +
 board/emk/common/vpd.c |   71 +++-
 board/emk/top7000/Makefile |   41 +++
 board/emk/top7000/config.mk|3 +
 board/emk/top7000/top7000.c|  174 +
 board/emk/top7000/u-boot.lds   |   72 
 include/configs/top7000.h  |  217 
 11 files changed, 587 insertions(+), 7 deletions(-)
 create mode 100644 arch/avr32/include/asm/unaligned.h
 create mode 100644 board/emk/top7000/Makefile
 create mode 100644 board/emk/top7000/config.mk
 create mode 100644 board/emk/top7000/top7000.c
 create mode 100644 board/emk/top7000/u-boot.lds
 create mode 100644 include/configs/top7000.h

diff --git a/MAINTAINERS b/MAINTAINERS
index 7a13d28..a361be1 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -311,7 +311,7 @@ Andrea "llandre" Marson 
 
PPChameleonEVB  PPC405EP
 
-Reinhard Meyer 
+Reinhard Meyer 
 
TOP860  MPC860T
TOP5200 MPC5200
@@ -919,6 +919,10 @@ Julien May 
 
HAMMERHEAD  AT32AP7000
 
+Reinhard Meyer 
+
+   TOP7000 AT32AP7000
+
 Haavard Skinnemoen 
 
ATSTK1000   AT32AP7xxx
diff --git a/MAKEALL b/MAKEALL
index 2527352..016f6ef 100755
--- a/MAKEALL
+++ b/MAKEALL
@@ -874,6 +874,7 @@ LIST_avr32="\
favr-32-ezkit   \
hammerhead  \
mimc200 \
+   top7000 \
 "
 
 #
diff --git a/Makefile b/Makefile
index c26e491..e57a4ca 100644
--- a/Makefile
+++ b/Makefile
@@ -3549,6 +3549,9 @@ hammerhead_config :   unconfig
 mimc200_config :   unconfig
@$(MKCONFIG) $(@:_config=) avr32 at32ap mimc200 mimc at32ap700x
 
+top7000_config :   unconfig
+   @$(MKCONFIG) $(@:_config=) avr32 at32ap top7000 emk at32ap700x
+
 #
 # SH3 (SuperH)
 #
diff --git a/arch/avr32/include/asm/unaligned.h 
b/arch/avr32/include/asm/unaligned.h
new file mode 100644
index 000..6cecbbb
--- /dev/null
+++ b/arch/avr32/include/asm/unaligned.h
@@ -0,0 +1 @@
+#include 
diff --git a/arch/avr32/lib/board.c b/arch/avr32/lib/board.c
index 917ed6c..6be5ab0 100644
--- a/arch/avr32/lib/board.c
+++ b/arch/avr32/lib/board.c
@@ -337,6 +337,11 @@ void board_init_r(gd_t *new_gd, ulong dest_addr)
jumptable_init();
console_init_r();
 
+#if defined(CONFIG_MISC_INIT_R)
+   /* miscellaneous platform dependent initialisations */
+   misc_init_r();
+#endif
+
s = getenv("loadaddr");
if (s)
load_addr = simple_strtoul(s, NULL, 16);
diff --git a/board/emk/common/vpd.c b/board/emk/common/vpd.c
index c2af219..d2c8af2 100644
--- a/board/emk/common/vpd.c
+++ b/board/emk/common/vpd.c
@@ -1,6 +1,6 @@
 /*
- * (C) Copyright 2003
- * Reinhard Meyer, EMK Elektronik GmbH, r.me...@emk-elektronik.de
+ * (C) Copyright 2003-2010
+ * EMK Elektronik GmbH & Co. KG, reinhard.me...@emk-elektronik.de
  *
  * See file CREDITS for list of people who contributed to this
  * project.
@@ -22,10 +22,9 @@
  */
 
 #include 
-
-/*
- * read "factory" part of EEPROM and set some environment variables
- */
+#include 
+
+/* read "factory" part of EEPROM and set some environment variables */
 void read_factory_r (void)
 {
/* read 'factory' part of EEPROM */
@@ -70,6 +69,10 @@ void read_factory_r (void)
/* search for our specific entry */
if (!strncmp ((char *) buf, "[RLA/lan/Ethernet] ", 19)) {
setenv ("ethaddr", (char *)(buf + 19));
+#if defined(CONFIG_TOP7000)
+   } else if (!strncmp ((char *) buf, "[RLA/lan2/Ethernet] ", 20)) 
{
+   setenv ("eth1addr", (char *)(buf + 20));
+#endif
} else if (!strncmp ((char *) buf, "[BOARD/SERIAL] ", 15)) {
setenv ("serial#", (char *)(buf + 15));
} else if (!strncmp ((char *) buf, "[BOARD/TYPE] ", 13)) {
@@ -77,3 +80,59 @@ void read_factory_r (void)
}
}
 }
+
+#if defined(CONFIG_TOP7000_VPD) && defin