Re: [U-Boot] [PATCH][Net] Convert SMC91111 Ethernet driver to CONFIG_NET_MULTI API

2009-09-22 Thread Wolfgang Denk
Dear Mike Frysinger,

In message 200909110606.42732.vap...@gentoo.org you wrote:
 --===0077506097==
 Content-Type: multipart/signed;
   boundary=nextPart2279044.usXPOpWbKs;
   protocol=application/pgp-signature;
   micalg=pgp-sha1
 Content-Transfer-Encoding: 7bit
 
 --nextPart2279044.usXPOpWbKs
 Content-Type: multipart/mixed;
   boundary=Boundary-01=_rEiqKxzcR2Mk9j/
 Content-Transfer-Encoding: 7bit
 
 
 --Boundary-01=_rEiqKxzcR2Mk9j/
 Content-Type: Text/Plain;
   charset=utf-8
 Content-Transfer-Encoding: quoted-printable
 Content-Disposition: inline

Please do not do that. Patches are supposed to be submitten inline.

Except for that:

Acked-by: Wolfgang Denk w...@denx.de

Best regards,

Wolfgang Denk

-- 
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: w...@denx.de
We don't care.  We don't have to.  We're the Phone Company.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH][Net] Convert SMC91111 Ethernet driver to CONFIG_NET_MULTI API

2009-09-10 Thread Ben Warren
Mike Frysinger wrote:
 the attached patch incorporates my changes and has been tested on actual 
 hardware with 2009.08
 -mike
Thanks a lot.  I'm applying it to the net tree.

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


Re: [U-Boot] [PATCH][Net] Convert SMC91111 Ethernet driver to CONFIG_NET_MULTI API

2009-09-02 Thread Mike Frysinger
On Monday 27 July 2009 17:43:22 Ben Warren wrote:
 diff --git a/include/configs/blackstamp.h b/include/configs/blackstamp.h
 index 887f3fb..6c9b3e0 100644
 --- a/include/configs/blackstamp.h
 +++ b/include/configs/blackstamp.h
 @@ -30,7 +30,8 @@
  /*
   * Board settings
   */
 -#define CONFIG_DRIVER_SMC9   1
 +#define CONFIG_NET_MULTI
 +#define CONFIG_SMC9  1
  #define CONFIG_SMC9_BASE 0x20300300

  /* FLASH/ETHERNET uses the same address range

change to this header is incomplete.  it needs this additional change:

--- include/configs/blackstamp.h
+++ include/configs/blackstamp.h
@@ -70,7 +70,7 @@
  * Network settings
  */
 
-#ifdef CONFIG_DRIVER_SMC9
+#ifdef CONFIG_SMC9
 #define CONFIG_IPADDR  192.168.0.15
 #define CONFIG_NETMASK 255.255.255.0
 #define CONFIG_GATEWAYIP   192.168.0.1
@@ -109,7 +109,7 @@
 
 #include config_cmd_default.h
 
-#ifdef CONFIG_DRIVER_SMC9
+#ifdef CONFIG_SMC9
 # define CONFIG_CMD_DHCP
 # define CONFIG_CMD_PING
 #else
-mike


signature.asc
Description: This is a digitally signed message part.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH][Net] Convert SMC91111 Ethernet driver to CONFIG_NET_MULTI API

2009-08-25 Thread Ben Warren
Hi Robin,

Robin Getz wrote:
 On Mon 27 Jul 2009 17:47, Ben Warren pondered:
   
 Ben Warren wrote:
 
 All in-tree boards that use this controller have CONFIG_NET_MULTI
 added
 Also:
   - changed CONFIG_DRIVER_SMC9 to CONFIG_SMC9
   - cleaned up line lengths
   - modified all boards that override weak function in this driver
   - modified all eeprom standalone apps to work with new driver

 Signed-off-by: Ben Warren biggerbadder...@gmail.com
   
 This patch is pretty big (~98k) and should probably be split up in its 
 final incarnation.  This is really meant as a test patch.

 Since I don't have boards with this chip family, I'm unable to test for 
 anything beyond clean compiling.  I don't have a blackfin toolchain 
 installed, but it does build cleanly on 'MAKEALL ARM9' using ELDK 4.1 
 for ARM.

 If anybody is able to test, please do and let me know the results.
 

 I have a few boards in the office - I'll try tomorrow.

   
Did you ever get a chance to try this out?  If it works for you, I'll 
send out v2 addressing some style stuff.

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


Re: [U-Boot] [PATCH][Net] Convert SMC91111 Ethernet driver to CONFIG_NET_MULTI API

2009-07-27 Thread Ben Warren
Ben Warren wrote:
 All in-tree boards that use this controller have CONFIG_NET_MULTI
 added
 Also:
   - changed CONFIG_DRIVER_SMC9 to CONFIG_SMC9
   - cleaned up line lengths
   - modified all boards that override weak function in this driver
   - modified all eeprom standalone apps to work with new driver

 Signed-off-by: Ben Warren biggerbadder...@gmail.com
This patch is pretty big (~98k) and should probably be split up in its 
final incarnation.  This is really meant as a test patch.

Since I don't have boards with this chip family, I'm unable to test for 
anything beyond clean compiling.  I don't have a blackfin toolchain 
installed, but it does build cleanly on 'MAKEALL ARM9' using ELDK 4.1 
for ARM.

If anybody is able to test, please do and let me know the results.

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


Re: [U-Boot] [PATCH][Net] Convert SMC91111 Ethernet driver to CONFIG_NET_MULTI API

2009-07-27 Thread Robin Getz
On Mon 27 Jul 2009 17:47, Ben Warren pondered:
 Ben Warren wrote:
  All in-tree boards that use this controller have CONFIG_NET_MULTI
  added
  Also:
- changed CONFIG_DRIVER_SMC9 to CONFIG_SMC9
- cleaned up line lengths
- modified all boards that override weak function in this driver
- modified all eeprom standalone apps to work with new driver
 
  Signed-off-by: Ben Warren biggerbadder...@gmail.com
 This patch is pretty big (~98k) and should probably be split up in its 
 final incarnation.  This is really meant as a test patch.
 
 Since I don't have boards with this chip family, I'm unable to test for 
 anything beyond clean compiling.  I don't have a blackfin toolchain 
 installed, but it does build cleanly on 'MAKEALL ARM9' using ELDK 4.1 
 for ARM.
 
 If anybody is able to test, please do and let me know the results.

I have a few boards in the office - I'll try tomorrow.

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


Re: [U-Boot] [PATCH][Net] Convert SMC91111 Ethernet driver to CONFIG_NET_MULTI API

2009-07-27 Thread Robin Getz
On Mon 27 Jul 2009 17:47, Ben Warren pondered:
 Ben Warren wrote:
  All in-tree boards that use this controller have CONFIG_NET_MULTI
  added
  Also:
- changed CONFIG_DRIVER_SMC9 to CONFIG_SMC9
- cleaned up line lengths
- modified all boards that override weak function in this driver
- modified all eeprom standalone apps to work with new driver
 
  Signed-off-by: Ben Warren biggerbadder...@gmail.com
 This patch is pretty big (~98k) and should probably be split up in its 
 final incarnation.  This is really meant as a test patch.
 
 Since I don't have boards with this chip family, I'm unable to test for 
 anything beyond clean compiling.  I don't have a blackfin toolchain 
 installed,

There are always tarballs and rpms (source and binaries) at:
http://blackfin.uclinux.org/gf/project/toolchain/frs/?action=FrsReleaseBrowsefrs_package_id=127

 but it does build cleanly on 'MAKEALL ARM9' using ELDK 4.1  
 for ARM.
 
 If anybody is able to test, please do and let me know the results.
 
 regards,
 Ben
 ___
 U-Boot mailing list
 U-Boot@lists.denx.de
 http://lists.denx.de/mailman/listinfo/u-boot
 
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH][Net] Convert SMC91111 Ethernet driver to CONFIG_NET_MULTI API

2009-07-27 Thread Mike Frysinger
On Monday 27 July 2009 17:43:22 Ben Warren wrote:
 All in-tree boards that use this controller have CONFIG_NET_MULTI
 added
 Also:
   - changed CONFIG_DRIVER_SMC9 to CONFIG_SMC9
   - cleaned up line lengths
   - modified all boards that override weak function in this driver
   - modified all eeprom standalone apps to work with new driver

annoyingly, i dont have any of the boards with me, so my attached changes are
only compile tested for Blackfin boards.

 - fix enetaddr handling
 - scrub dead functions
 - drop stub func indirection
 - fix possible memleak in initialize func
 - tweak Blackin board style
-mike

diff --git a/board/bf533-ezkit/bf533-ezkit.c b/board/bf533-ezkit/bf533-ezkit.c
index ff0e15e..8727dee 100644
--- a/board/bf533-ezkit/bf533-ezkit.c
+++ b/board/bf533-ezkit/bf533-ezkit.c
@@ -59,13 +59,9 @@ int misc_init_r(void)
return 0;
 }
 
-#ifdef CONFIG_CMD_NET
+#ifdef CONFIG_SMC9
 int board_eth_init(bd_t *bis)
 {
-   int rc = 0;
-#ifdef CONFIG_SMC9
-   rc = smc9_initialize(0, CONFIG_SMC9_BASE);
-#endif
-   return rc;
+   return smc9_initialize(0, CONFIG_SMC9_BASE);
 }
 #endif
diff --git a/board/bf533-stamp/bf533-stamp.c b/board/bf533-stamp/bf533-stamp.c
index 32e7174..a226910 100644
--- a/board/bf533-stamp/bf533-stamp.c
+++ b/board/bf533-stamp/bf533-stamp.c
@@ -285,13 +285,9 @@ void __led_toggle(led_id_t mask)
 
 #endif
 
-#ifdef CONFIG_CMD_NET
+#ifdef CONFIG_SMC9
 int board_eth_init(bd_t *bis)
 {
-   int rc = 0;
-#ifdef CONFIG_SMC9
-   rc = smc9_initialize(0, CONFIG_SMC9_BASE);
-#endif
-   return rc;
+   return smc9_initialize(0, CONFIG_SMC9_BASE);
 }
 #endif
diff --git a/board/bf538f-ezkit/bf538f-ezkit.c 
b/board/bf538f-ezkit/bf538f-ezkit.c
index 1897405..15916fa 100644
--- a/board/bf538f-ezkit/bf538f-ezkit.c
+++ b/board/bf538f-ezkit/bf538f-ezkit.c
@@ -27,13 +27,9 @@ phys_size_t initdram(int board_type)
return gd-bd-bi_memsize;
 }
 
-#ifdef CONFIG_CMD_NET
+#ifdef CONFIG_SMC9
 int board_eth_init(bd_t *bis)
 {
-   int rc = 0;
-#ifdef CONFIG_SMC9
-   rc = smc9_initialize(0, CONFIG_SMC9_BASE);
-#endif
-   return rc;
+   return smc9_initialize(0, CONFIG_SMC9_BASE);
 }
 #endif
diff --git a/board/bf561-ezkit/bf561-ezkit.c b/board/bf561-ezkit/bf561-ezkit.c
index 24347e2..e5d7eb3 100644
--- a/board/bf561-ezkit/bf561-ezkit.c
+++ b/board/bf561-ezkit/bf561-ezkit.c
@@ -45,13 +45,9 @@ phys_size_t initdram(int board_type)
return gd-bd-bi_memsize;
 }
 
-#ifdef CONFIG_CMD_NET
+#ifdef CONFIG_SMC9
 int board_eth_init(bd_t *bis)
 {
-   int rc = 0;
-#ifdef CONFIG_SMC9
-   rc = smc9_initialize(0, CONFIG_SMC9_BASE);
-#endif
-   return rc;
+   return smc9_initialize(0, CONFIG_SMC9_BASE);
 }
 #endif
diff --git a/board/blackstamp/blackstamp.c b/board/blackstamp/blackstamp.c
index 524c86c..f55ab97 100644
--- a/board/blackstamp/blackstamp.c
+++ b/board/blackstamp/blackstamp.c
@@ -46,13 +46,9 @@ void swap_to(int device_id)
 }
 #endif
 
-#ifdef CONFIG_CMD_NET
+#ifdef CONFIG_SMC9
 int board_eth_init(bd_t *bis)
 {
-   int rc = 0;
-#ifdef CONFIG_SMC9
-   rc = smc9_initialize(0, CONFIG_SMC9_BASE);
-#endif
-   return rc;
+   return smc9_initialize(0, CONFIG_SMC9_BASE);
 }
 #endif
diff --git a/board/cm-bf533/cm-bf533.c b/board/cm-bf533/cm-bf533.c
index 6598e27..ab0bf3b 100644
--- a/board/cm-bf533/cm-bf533.c
+++ b/board/cm-bf533/cm-bf533.c
@@ -25,13 +25,9 @@ phys_size_t initdram(int board_type)
return gd-bd-bi_memsize;
 }
 
-#ifdef CONFIG_CMD_NET
+#ifdef CONFIG_SMC9
 int board_eth_init(bd_t *bis)
 {
-   int rc = 0;
-#ifdef CONFIG_SMC9
-   rc = smc9_initialize(0, CONFIG_SMC9_BASE);
-#endif
-   return rc;
+   return smc9_initialize(0, CONFIG_SMC9_BASE);
 }
 #endif
diff --git a/board/cm-bf561/cm-bf561.c b/board/cm-bf561/cm-bf561.c
index b204d7c..f21a015 100644
--- a/board/cm-bf561/cm-bf561.c
+++ b/board/cm-bf561/cm-bf561.c
@@ -25,13 +25,9 @@ phys_size_t initdram(int board_type)
return gd-bd-bi_memsize;
 }
 
-#ifdef CONFIG_CMD_NET
+#ifdef CONFIG_SMC9
 int board_eth_init(bd_t *bis)
 {
-   int rc = 0;
-#ifdef CONFIG_SMC9
-   rc = smc9_initialize(0, CONFIG_SMC9_BASE);
-#endif
-   return rc;
+   return smc9_initialize(0, CONFIG_SMC9_BASE);
 }
 #endif
diff --git a/drivers/net/smc9.c b/drivers/net/smc9.c
index 5974c4d..673b52d 100644
--- a/drivers/net/smc9.c
+++ b/drivers/net/smc9.c
@@ -123,7 +123,6 @@ static const char version[] =
  . what you are doing.
  .
  -*/
-#define CARDNAME LAN91C111
 
 /* Memory sizing constant */
 #define LAN91C111_MEMORY_MULTIPLIER(1024*2)
@@ -147,33 +146,15 @@ static const char version[] =
 #else
 #undef USE_32_BIT
 #endif
-/*-
- .
- .