blob: 1b56a356c4f4544623b1093b6ef614dd1ff21a38 [file] [log] [blame]
wdenkc6097192002-11-03 00:24:07 +00001/*
wdenk1ebf41e2004-01-02 14:00:00 +00002 * (C) Copyright 2001-2004
wdenkc6097192002-11-03 00:24:07 +00003 * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
4 *
5 * See file CREDITS for list of people who contributed to this
6 * project.
7 *
8 * This program is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU General Public License as
10 * published by the Free Software Foundation; either version 2 of
11 * the License, or (at your option) any later version.
12 *
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
17 *
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
21 * MA 02111-1307 USA
22 */
23
24#include <common.h>
25#include <command.h>
26#include <net.h>
Marian Balakowiczcbdd1c82005-11-30 18:06:04 +010027#include <miiphy.h>
wdenkc6097192002-11-03 00:24:07 +000028
Jon Loeliger54f35c22007-07-09 17:45:14 -050029#if defined(CONFIG_CMD_NET) && defined(CONFIG_NET_MULTI)
wdenkc6097192002-11-03 00:24:07 +000030
31#ifdef CFG_GT_6426x
32extern int gt6426x_eth_initialize(bd_t *bis);
33#endif
34
wdenk5da7f2f2004-01-03 00:43:19 +000035extern int au1x00_enet_initialize(bd_t*);
36extern int dc21x4x_initialize(bd_t*);
wdenk4e112c12003-06-03 23:54:09 +000037extern int e1000_initialize(bd_t*);
wdenkc6097192002-11-03 00:24:07 +000038extern int eepro100_initialize(bd_t*);
wdenk452cfd62002-11-19 11:04:11 +000039extern int eth_3com_initialize(bd_t*);
wdenkc6097192002-11-03 00:24:07 +000040extern int fec_initialize(bd_t*);
wdenk4fc95692003-02-28 00:49:47 +000041extern int inca_switch_initialize(bd_t*);
wdenk21136db2003-07-16 21:53:01 +000042extern int mpc5xxx_fec_initialize(bd_t*);
Rafal Jaworowskid3a02c32007-07-27 14:43:59 +020043extern int mpc512x_fec_initialize(bd_t*);
wdenk337f5652004-10-28 00:09:35 +000044extern int mpc8220_fec_initialize(bd_t*);
wdenk5da7f2f2004-01-03 00:43:19 +000045extern int mv6436x_eth_initialize(bd_t *);
46extern int mv6446x_eth_initialize(bd_t *);
47extern int natsemi_initialize(bd_t*);
48extern int ns8382x_initialize(bd_t*);
49extern int pcnet_initialize(bd_t*);
50extern int plb2800_eth_initialize(bd_t*);
51extern int ppc_4xx_eth_initialize(bd_t *);
52extern int rtl8139_initialize(bd_t*);
wdenka6270482004-04-18 22:03:42 +000053extern int rtl8169_initialize(bd_t*);
wdenk5da7f2f2004-01-03 00:43:19 +000054extern int scc_initialize(bd_t*);
wdenkeb20ad32003-09-05 23:19:14 +000055extern int skge_initialize(bd_t*);
roy zang72526f72006-11-02 19:08:55 +080056extern int tsi108_eth_initialize(bd_t*);
Roy Zang99762232007-11-05 17:39:24 +080057extern int uli526x_initialize(bd_t *);
Jon Loeliger77a4f6e2005-07-25 14:05:07 -050058extern int tsec_initialize(bd_t*, int, char *);
Wolfgang Denk4646d2a2006-05-30 15:56:48 +020059extern int npe_initialize(bd_t *);
Dave Liue732e9c2006-11-03 12:11:15 -060060extern int uec_initialize(int);
Aubrey Li570dc1e2007-04-05 18:30:25 +080061extern int bfin_EMAC_initialize(bd_t *);
Haavard Skinnemoen58f4c262006-12-17 17:14:30 +010062extern int atstk1000_eth_initialize(bd_t *);
TsiChung Liewf6afe722007-06-18 13:50:13 -050063extern int mcffec_initialize(bd_t*);
wdenkc6097192002-11-03 00:24:07 +000064
65static struct eth_device *eth_devices, *eth_current;
66
67struct eth_device *eth_get_dev(void)
68{
69 return eth_current;
70}
71
Marian Balakowiczaab8c492005-10-28 22:30:33 +020072struct eth_device *eth_get_dev_by_name(char *devname)
73{
74 struct eth_device *dev, *target_dev;
75
76 if (!eth_devices)
77 return NULL;
78
79 dev = eth_devices;
80 target_dev = NULL;
81 do {
82 if (strcmp(devname, dev->name) == 0) {
83 target_dev = dev;
84 break;
85 }
86 dev = dev->next;
87 } while (dev != eth_devices);
88
89 return target_dev;
90}
91
wdenkc6097192002-11-03 00:24:07 +000092int eth_get_dev_index (void)
93{
94 struct eth_device *dev;
95 int num = 0;
96
97 if (!eth_devices) {
98 return (-1);
99 }
100
101 for (dev = eth_devices; dev; dev = dev->next) {
102 if (dev == eth_current)
103 break;
104 ++num;
105 }
106
107 if (dev) {
108 return (num);
109 }
110
111 return (0);
112}
113
114int eth_register(struct eth_device* dev)
115{
116 struct eth_device *d;
117
118 if (!eth_devices) {
119 eth_current = eth_devices = dev;
wdenk145d2c12004-04-15 21:48:45 +0000120#ifdef CONFIG_NET_MULTI
121 /* update current ethernet name */
122 {
123 char *act = getenv("ethact");
124 if (act == NULL || strcmp(act, eth_current->name) != 0)
125 setenv("ethact", eth_current->name);
126 }
127#endif
wdenkc6097192002-11-03 00:24:07 +0000128 } else {
129 for (d=eth_devices; d->next!=eth_devices; d=d->next);
130 d->next = dev;
131 }
132
133 dev->state = ETH_STATE_INIT;
134 dev->next = eth_devices;
135
136 return 0;
137}
138
139int eth_initialize(bd_t *bis)
140{
Wolfgang Denk7fb52662005-10-13 16:45:02 +0200141 char enetvar[32], env_enetaddr[6];
wdenkc6097192002-11-03 00:24:07 +0000142 int i, eth_number = 0;
143 char *tmp, *end;
144
145 eth_devices = NULL;
146 eth_current = NULL;
147
Heiko Schocher8a8ec532007-07-13 09:54:17 +0200148 show_boot_progress (64);
Jon Loeliger54f35c22007-07-09 17:45:14 -0500149#if defined(CONFIG_MII) || defined(CONFIG_CMD_MII)
Marian Balakowiczcbdd1c82005-11-30 18:06:04 +0100150 miiphy_init();
151#endif
152
Stefan Roese45993ea2006-11-29 15:42:37 +0100153#if defined(CONFIG_DB64360) || defined(CONFIG_CPCI750)
wdenk5da7f2f2004-01-03 00:43:19 +0000154 mv6436x_eth_initialize(bis);
155#endif
Stefan Roese45993ea2006-11-29 15:42:37 +0100156#if defined(CONFIG_DB64460) || defined(CONFIG_P3Mx)
wdenk5da7f2f2004-01-03 00:43:19 +0000157 mv6446x_eth_initialize(bis);
158#endif
Wolfgang Denk56811f62005-10-09 01:04:33 +0200159#if defined(CONFIG_4xx) && !defined(CONFIG_IOP480) && !defined(CONFIG_AP1000)
wdenk57b2d802003-06-27 21:31:46 +0000160 ppc_4xx_eth_initialize(bis);
wdenk77934442003-06-05 19:37:36 +0000161#endif
wdenk4fc95692003-02-28 00:49:47 +0000162#ifdef CONFIG_INCA_IP_SWITCH
163 inca_switch_initialize(bis);
164#endif
wdenkb02744a2003-04-05 00:53:31 +0000165#ifdef CONFIG_PLB2800_ETHER
166 plb2800_eth_initialize(bis);
167#endif
wdenk63a10be2004-05-08 20:33:20 +0000168#ifdef SCC_ENET
169 scc_initialize(bis);
170#endif
wdenk63a10be2004-05-08 20:33:20 +0000171#if defined(CONFIG_MPC5xxx_FEC)
172 mpc5xxx_fec_initialize(bis);
173#endif
Rafal Jaworowskid3a02c32007-07-27 14:43:59 +0200174#if defined(CONFIG_MPC512x_FEC)
175 mpc512x_fec_initialize (bis);
176#endif
wdenk5c71a7a2005-05-16 15:23:22 +0000177#if defined(CONFIG_MPC8220_FEC)
wdenk337f5652004-10-28 00:09:35 +0000178 mpc8220_fec_initialize(bis);
179#endif
wdenk63a10be2004-05-08 20:33:20 +0000180#if defined(CONFIG_SK98)
181 skge_initialize(bis);
182#endif
Kim Phillips177e58f2007-05-16 16:52:19 -0500183#if defined(CONFIG_TSEC1)
184 tsec_initialize(bis, 0, CONFIG_TSEC1_NAME);
wdenk13eb2212004-07-09 23:27:13 +0000185#endif
Kim Phillips177e58f2007-05-16 16:52:19 -0500186#if defined(CONFIG_TSEC2)
187 tsec_initialize(bis, 1, CONFIG_TSEC2_NAME);
wdenk13eb2212004-07-09 23:27:13 +0000188#endif
189#if defined(CONFIG_MPC85XX_FEC)
Jon Loeliger77a4f6e2005-07-25 14:05:07 -0500190 tsec_initialize(bis, 2, CONFIG_MPC85XX_FEC_NAME);
191#else
Kim Phillips177e58f2007-05-16 16:52:19 -0500192# if defined(CONFIG_TSEC3)
193 tsec_initialize(bis, 2, CONFIG_TSEC3_NAME);
Jon Loeliger77a4f6e2005-07-25 14:05:07 -0500194# endif
Kim Phillips177e58f2007-05-16 16:52:19 -0500195# if defined(CONFIG_TSEC4)
196 tsec_initialize(bis, 3, CONFIG_TSEC4_NAME);
Jon Loeliger77a4f6e2005-07-25 14:05:07 -0500197# endif
wdenk63a10be2004-05-08 20:33:20 +0000198#endif
Dave Liue732e9c2006-11-03 12:11:15 -0600199#if defined(CONFIG_UEC_ETH1)
200 uec_initialize(0);
201#endif
202#if defined(CONFIG_UEC_ETH2)
203 uec_initialize(1);
204#endif
Jon Loeliger5c8aa972006-04-26 17:58:56 -0500205
Stefan Roese09554022005-11-30 13:06:40 +0100206#if defined(FEC_ENET) || defined(CONFIG_ETHER_ON_FCC)
207 fec_initialize(bis);
208#endif
wdenk63a10be2004-05-08 20:33:20 +0000209#if defined(CONFIG_AU1X00)
210 au1x00_enet_initialize(bis);
211#endif
Wolfgang Denk4646d2a2006-05-30 15:56:48 +0200212#if defined(CONFIG_IXP4XX_NPE)
213 npe_initialize(bis);
214#endif
wdenk4e112c12003-06-03 23:54:09 +0000215#ifdef CONFIG_E1000
216 e1000_initialize(bis);
217#endif
wdenkc6097192002-11-03 00:24:07 +0000218#ifdef CONFIG_EEPRO100
219 eepro100_initialize(bis);
220#endif
221#ifdef CONFIG_TULIP
222 dc21x4x_initialize(bis);
223#endif
wdenk452cfd62002-11-19 11:04:11 +0000224#ifdef CONFIG_3COM
225 eth_3com_initialize(bis);
226#endif
wdenkc6097192002-11-03 00:24:07 +0000227#ifdef CONFIG_PCNET
228 pcnet_initialize(bis);
229#endif
230#ifdef CFG_GT_6426x
231 gt6426x_eth_initialize(bis);
232#endif
233#ifdef CONFIG_NATSEMI
234 natsemi_initialize(bis);
235#endif
236#ifdef CONFIG_NS8382X
237 ns8382x_initialize(bis);
238#endif
roy zang72526f72006-11-02 19:08:55 +0800239#if defined(CONFIG_TSI108_ETH)
240 tsi108_eth_initialize(bis);
241#endif
Roy Zang99762232007-11-05 17:39:24 +0800242#if defined(CONFIG_ULI526X)
243 uli526x_initialize(bis);
244#endif
wdenk0260cd62004-01-02 15:01:32 +0000245#if defined(CONFIG_RTL8139)
246 rtl8139_initialize(bis);
247#endif
wdenka6270482004-04-18 22:03:42 +0000248#if defined(CONFIG_RTL8169)
249 rtl8169_initialize(bis);
250#endif
Aubrey Li570dc1e2007-04-05 18:30:25 +0800251#if defined(CONFIG_BF537)
252 bfin_EMAC_initialize(bis);
253#endif
Haavard Skinnemoen58f4c262006-12-17 17:14:30 +0100254#if defined(CONFIG_ATSTK1000)
255 atstk1000_eth_initialize(bis);
256#endif
TsiChungLiew507bd712007-07-05 23:29:21 -0500257#if defined(CONFIG_MCFFEC)
258 mcffec_initialize(bis);
259#endif
wdenkc6097192002-11-03 00:24:07 +0000260
261 if (!eth_devices) {
262 puts ("No ethernet found.\n");
Heiko Schocher8a8ec532007-07-13 09:54:17 +0200263 show_boot_progress (-64);
wdenkc6097192002-11-03 00:24:07 +0000264 } else {
265 struct eth_device *dev = eth_devices;
266 char *ethprime = getenv ("ethprime");
267
Heiko Schocher8a8ec532007-07-13 09:54:17 +0200268 show_boot_progress (65);
wdenkc6097192002-11-03 00:24:07 +0000269 do {
270 if (eth_number)
271 puts (", ");
272
273 printf("%s", dev->name);
274
275 if (ethprime && strcmp (dev->name, ethprime) == 0) {
276 eth_current = dev;
277 puts (" [PRIME]");
278 }
279
280 sprintf(enetvar, eth_number ? "eth%daddr" : "ethaddr", eth_number);
281 tmp = getenv (enetvar);
282
283 for (i=0; i<6; i++) {
284 env_enetaddr[i] = tmp ? simple_strtoul(tmp, &end, 16) : 0;
285 if (tmp)
286 tmp = (*end) ? end+1 : end;
287 }
288
289 if (memcmp(env_enetaddr, "\0\0\0\0\0\0", 6)) {
290 if (memcmp(dev->enetaddr, "\0\0\0\0\0\0", 6) &&
291 memcmp(dev->enetaddr, env_enetaddr, 6))
292 {
wdenk63a10be2004-05-08 20:33:20 +0000293 printf ("\nWarning: %s MAC addresses don't match:\n",
294 dev->name);
295 printf ("Address in SROM is "
wdenkc6097192002-11-03 00:24:07 +0000296 "%02X:%02X:%02X:%02X:%02X:%02X\n",
297 dev->enetaddr[0], dev->enetaddr[1],
298 dev->enetaddr[2], dev->enetaddr[3],
299 dev->enetaddr[4], dev->enetaddr[5]);
wdenk63a10be2004-05-08 20:33:20 +0000300 printf ("Address in environment is "
wdenkc6097192002-11-03 00:24:07 +0000301 "%02X:%02X:%02X:%02X:%02X:%02X\n",
302 env_enetaddr[0], env_enetaddr[1],
303 env_enetaddr[2], env_enetaddr[3],
304 env_enetaddr[4], env_enetaddr[5]);
305 }
306
307 memcpy(dev->enetaddr, env_enetaddr, 6);
308 }
309
310 eth_number++;
311 dev = dev->next;
312 } while(dev != eth_devices);
313
wdenk145d2c12004-04-15 21:48:45 +0000314#ifdef CONFIG_NET_MULTI
315 /* update current ethernet name */
316 if (eth_current) {
317 char *act = getenv("ethact");
318 if (act == NULL || strcmp(act, eth_current->name) != 0)
319 setenv("ethact", eth_current->name);
320 } else
321 setenv("ethact", NULL);
322#endif
323
wdenkc6097192002-11-03 00:24:07 +0000324 putc ('\n');
325 }
326
327 return eth_number;
328}
329
330void eth_set_enetaddr(int num, char *addr) {
331 struct eth_device *dev;
332 unsigned char enetaddr[6];
333 char *end;
334 int i;
335
wdenk1ebf41e2004-01-02 14:00:00 +0000336 debug ("eth_set_enetaddr(num=%d, addr=%s)\n", num, addr);
337
wdenkc6097192002-11-03 00:24:07 +0000338 if (!eth_devices)
339 return;
340
341 for (i=0; i<6; i++) {
342 enetaddr[i] = addr ? simple_strtoul(addr, &end, 16) : 0;
343 if (addr)
344 addr = (*end) ? end+1 : end;
345 }
346
347 dev = eth_devices;
348 while(num-- > 0) {
349 dev = dev->next;
350
351 if (dev == eth_devices)
352 return;
353 }
354
wdenk1ebf41e2004-01-02 14:00:00 +0000355 debug ( "Setting new HW address on %s\n"
356 "New Address is %02X:%02X:%02X:%02X:%02X:%02X\n",
357 dev->name,
Wolfgang Denkb6ea6302005-09-25 17:05:57 +0200358 enetaddr[0], enetaddr[1],
359 enetaddr[2], enetaddr[3],
360 enetaddr[4], enetaddr[5]);
wdenkc6097192002-11-03 00:24:07 +0000361
362 memcpy(dev->enetaddr, enetaddr, 6);
363}
David Updegraff7280da72007-06-11 10:41:07 -0500364#ifdef CONFIG_MCAST_TFTP
365/* Multicast.
366 * mcast_addr: multicast ipaddr from which multicast Mac is made
Wolfgang Denk627f5c32007-08-14 09:47:27 +0200367 * join: 1=join, 0=leave.
David Updegraff7280da72007-06-11 10:41:07 -0500368 */
369int eth_mcast_join( IPaddr_t mcast_ip, u8 join)
370{
371 u8 mcast_mac[6];
Wolfgang Denk627f5c32007-08-14 09:47:27 +0200372 if (!eth_current || !eth_current->mcast)
David Updegraff7280da72007-06-11 10:41:07 -0500373 return -1;
374 mcast_mac[5] = htonl(mcast_ip) & 0xff;
375 mcast_mac[4] = (htonl(mcast_ip)>>8) & 0xff;
376 mcast_mac[3] = (htonl(mcast_ip)>>16) & 0x7f;
377 mcast_mac[2] = 0x5e;
378 mcast_mac[1] = 0x0;
379 mcast_mac[0] = 0x1;
380 return eth_current->mcast(eth_current, mcast_mac, join);
381}
382
Wolfgang Denk627f5c32007-08-14 09:47:27 +0200383/* the 'way' for ethernet-CRC-32. Spliced in from Linux lib/crc32.c
384 * and this is the ethernet-crc method needed for TSEC -- and perhaps
David Updegraff7280da72007-06-11 10:41:07 -0500385 * some other adapter -- hash tables
386 */
387#define CRCPOLY_LE 0xedb88320
388u32 ether_crc (size_t len, unsigned char const *p)
389{
390 int i;
391 u32 crc;
392 crc = ~0;
393 while (len--) {
394 crc ^= *p++;
395 for (i = 0; i < 8; i++)
396 crc = (crc >> 1) ^ ((crc & 1) ? CRCPOLY_LE : 0);
397 }
398 /* an reverse the bits, cuz of way they arrive -- last-first */
399 crc = (crc >> 16) | (crc << 16);
400 crc = (crc >> 8 & 0x00ff00ff) | (crc << 8 & 0xff00ff00);
401 crc = (crc >> 4 & 0x0f0f0f0f) | (crc << 4 & 0xf0f0f0f0);
402 crc = (crc >> 2 & 0x33333333) | (crc << 2 & 0xcccccccc);
403 crc = (crc >> 1 & 0x55555555) | (crc << 1 & 0xaaaaaaaa);
404 return crc;
405}
wdenkc6097192002-11-03 00:24:07 +0000406
David Updegraff7280da72007-06-11 10:41:07 -0500407#endif
408
wdenkc6097192002-11-03 00:24:07 +0000409
410int eth_init(bd_t *bis)
411{
412 struct eth_device* old_current;
413
414 if (!eth_current)
415 return 0;
416
417 old_current = eth_current;
418 do {
wdenk1ebf41e2004-01-02 14:00:00 +0000419 debug ("Trying %s\n", eth_current->name);
wdenkc6097192002-11-03 00:24:07 +0000420
421 if (eth_current->init(eth_current, bis)) {
422 eth_current->state = ETH_STATE_ACTIVE;
423
wdenkc6097192002-11-03 00:24:07 +0000424 return 1;
425 }
wdenk1ebf41e2004-01-02 14:00:00 +0000426 debug ("FAIL\n");
wdenkc6097192002-11-03 00:24:07 +0000427
428 eth_try_another(0);
429 } while (old_current != eth_current);
430
431 return 0;
432}
433
434void eth_halt(void)
435{
436 if (!eth_current)
437 return;
438
439 eth_current->halt(eth_current);
440
441 eth_current->state = ETH_STATE_PASSIVE;
442}
443
444int eth_send(volatile void *packet, int length)
445{
446 if (!eth_current)
447 return -1;
448
449 return eth_current->send(eth_current, packet, length);
450}
451
452int eth_rx(void)
453{
454 if (!eth_current)
455 return -1;
456
457 return eth_current->recv(eth_current);
458}
459
460void eth_try_another(int first_restart)
461{
462 static struct eth_device *first_failed = NULL;
463
464 if (!eth_current)
465 return;
466
wdenk63a10be2004-05-08 20:33:20 +0000467 if (first_restart) {
wdenkc6097192002-11-03 00:24:07 +0000468 first_failed = eth_current;
469 }
470
471 eth_current = eth_current->next;
472
wdenk145d2c12004-04-15 21:48:45 +0000473#ifdef CONFIG_NET_MULTI
474 /* update current ethernet name */
475 {
476 char *act = getenv("ethact");
477 if (act == NULL || strcmp(act, eth_current->name) != 0)
478 setenv("ethact", eth_current->name);
479 }
480#endif
481
wdenk63a10be2004-05-08 20:33:20 +0000482 if (first_failed == eth_current) {
wdenkc6097192002-11-03 00:24:07 +0000483 NetRestartWrap = 1;
484 }
485}
486
wdenk145d2c12004-04-15 21:48:45 +0000487#ifdef CONFIG_NET_MULTI
488void eth_set_current(void)
489{
490 char *act;
491 struct eth_device* old_current;
492
493 if (!eth_current) /* XXX no current */
494 return;
495
496 act = getenv("ethact");
497 if (act != NULL) {
498 old_current = eth_current;
499 do {
500 if (strcmp(eth_current->name, act) == 0)
501 return;
502 eth_current = eth_current->next;
503 } while (old_current != eth_current);
504 }
505
506 setenv("ethact", eth_current->name);
507}
508#endif
509
wdenkc6abb7e2003-11-17 21:14:37 +0000510char *eth_get_name (void)
511{
512 return (eth_current ? eth_current->name : "unknown");
513}
Jon Loeliger54f35c22007-07-09 17:45:14 -0500514#elif defined(CONFIG_CMD_NET) && !defined(CONFIG_NET_MULTI)
Marian Balakowiczaab8c492005-10-28 22:30:33 +0200515
516extern int at91rm9200_miiphy_initialize(bd_t *bis);
517extern int emac4xx_miiphy_initialize(bd_t *bis);
518extern int mcf52x2_miiphy_initialize(bd_t *bis);
519extern int ns7520_miiphy_initialize(bd_t *bis);
Sergey Kubushyne8f39122007-08-10 20:26:18 +0200520extern int dm644x_eth_miiphy_initialize(bd_t *bis);
521
Marian Balakowiczaab8c492005-10-28 22:30:33 +0200522
523int eth_initialize(bd_t *bis)
524{
Jon Loeliger54f35c22007-07-09 17:45:14 -0500525#if defined(CONFIG_MII) || defined(CONFIG_CMD_MII)
Marian Balakowiczcbdd1c82005-11-30 18:06:04 +0100526 miiphy_init();
527#endif
528
Marian Balakowiczaab8c492005-10-28 22:30:33 +0200529#if defined(CONFIG_AT91RM9200)
530 at91rm9200_miiphy_initialize(bis);
531#endif
532#if defined(CONFIG_4xx) && !defined(CONFIG_IOP480) \
533 && !defined(CONFIG_AP1000) && !defined(CONFIG_405)
534 emac4xx_miiphy_initialize(bis);
535#endif
536#if defined(CONFIG_MCF52x2)
537 mcf52x2_miiphy_initialize(bis);
538#endif
539#if defined(CONFIG_NETARM)
540 ns7520_miiphy_initialize(bis);
541#endif
Sergey Kubushyne8f39122007-08-10 20:26:18 +0200542#if defined(CONFIG_DRIVER_TI_EMAC)
543 dm644x_eth_miiphy_initialize(bis);
544#endif
Marian Balakowiczaab8c492005-10-28 22:30:33 +0200545 return 0;
546}
wdenkc6097192002-11-03 00:24:07 +0000547#endif