aboutsummaryrefslogtreecommitdiff
path: root/board/mpc8540eval
diff options
context:
space:
mode:
authorBen Warren <biggerbadderben@gmail.com>2008-08-31 10:45:44 -0700
committerBen Warren <biggerbadderben@gmail.com>2008-09-02 21:18:18 -0700
commit8ca0b3f99c4fce7a599dcaf92ae095496dc8c8e0 (patch)
treeba9fe46a4ee78f693f456bef7d8aa93662b09886 /board/mpc8540eval
parentad3381cf4167120db5c7b88e4970245e1d5c0a32 (diff)
Moved initialization of TULIP Ethernet controller to board_eth_init()
Affected boards: cu824 bab7xx adciop dasa_sim mousse mpc8540eval musenki mvblue pcippc2/pcippc6 sbc8240 stxssa Removed initialization of the driver from net/eth.c Signed-off-by: Ben Warren <biggerbadderben@gmail.com>
Diffstat (limited to 'board/mpc8540eval')
-rw-r--r--board/mpc8540eval/mpc8540eval.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/board/mpc8540eval/mpc8540eval.c b/board/mpc8540eval/mpc8540eval.c
index 7c54458a5..028a70fad 100644
--- a/board/mpc8540eval/mpc8540eval.c
+++ b/board/mpc8540eval/mpc8540eval.c
@@ -24,6 +24,7 @@
*/
#include <common.h>
+#include <netdev.h>
#include <asm/processor.h>
#include <asm/mmu.h>
#include <asm/immap_85xx.h>
@@ -247,3 +248,14 @@ long int fixed_sdram (void)
return (CFG_SDRAM_SIZE * 1024 * 1024);
}
#endif /* !defined(CONFIG_SPD_EEPROM) */
+
+int board_eth_init(bd_t *bis)
+{
+ /*
+ * This board either has PCI NICs or uses the CPU's TSECs
+ * pci_eth_init() will return 0 if no NICs found, so in that case
+ * returning -1 will force cpu_eth_init() to be called.
+ */
+ int num = pci_eth_init(bis);
+ return (num <= 0 ? -1 : num);
+}