u-boot/cpu/mpc8xx
Guennadi Liakhovetski d197ffd817 Fix and optimize MII operations on FEC (MPC8xx) controllers
This patch fixes several issues at least on a MPC885 based system with two
FEC interfaces used in MII mode.

1. PHY discovery should first read PHY_PHYIDR2 register and only then
   PHY_PHYIDR1 like cpu/mpc8xx/fec.c::mii_discover_phy() does it,
   otherwise the values read are wrong. Also notice, that PHY discovery
   cannot work on MPC88x / MPC87x in setups with both FECs active at all
   in its present form, because for both interfaces the registers from FEC
   1 are used to communicate over MII.

2. Remove code duplication for resetting the FEC by isolating it into a
   separate function.

3. Initialize MII on FEC 1 when communicating over FEC 2 in fec_init().

4. Optimize mii_init() to only reset the FEC 1 controller once.

5. Fix a typo in mii_init() using index i instead of j thus potentially
   leading to unpredictable results.

Signed-off-by: Guennadi Liakhovetski <lg@denx.de>
2008-01-09 14:52:04 +01:00
..
bedbug_860.c cpu/m*: Remove obsolete references to CONFIG_COMMANDS 2007-07-09 19:06:00 -05:00
commproc.c GCC-4.x fixes: clean up global data pointer initialization for all boards. 2006-03-31 18:32:53 +02:00
config.mk Code cleanup, especially MIPS for GCC 4.x 2005-12-04 00:40:34 +01:00
cpu.c GCC-4.x fixes: clean up global data pointer initialization for all boards. 2006-03-31 18:32:53 +02:00
cpu_init.c Support for spc1920 board. 2006-07-12 08:48:24 +02:00
fec.c Fix and optimize MII operations on FEC (MPC8xx) controllers 2008-01-09 14:52:04 +01:00
fec.h Initial revision 2000-12-14 10:04:19 +00:00
i2c.c GCC-4.x fixes: clean up global data pointer initialization for all boards. 2006-03-31 18:32:53 +02:00
interrupts.c * Fix problems caused by Robert Schwebel's cramfs patch 2004-01-04 16:28:35 +00:00
kgdb.S cpu/ rtc/ include/: Remove lingering references to CFG_CMD_* symbols. 2007-07-10 10:27:39 -05:00
lcd.c * Patch by Detlev Zundel, 30 Jun 2005: 2005-07-04 00:03:16 +00:00
Makefile Move "ar" flags to config.mk to allow for silent "make -s" 2006-10-09 01:02:05 +02:00
plprcr_write.S * Patch by Wolter Kamphuis, 15 Dec 2003: 2004-02-06 21:48:22 +00:00
scc.c cpu/ rtc/ include/: Remove lingering references to CFG_CMD_* symbols. 2007-07-10 10:27:39 -05:00
serial.c cpu/ rtc/ include/: Remove lingering references to CFG_CMD_* symbols. 2007-07-10 10:27:39 -05:00
speed.c TQM885D: Exchanged SDRAM timing by a more relaxed timing. 2007-12-27 01:59:50 +01:00
spi.c Cleanup for GCC-4.x 2005-10-13 16:45:02 +02:00
start.S [ppc] Fix build breakage for all non-4xx PowerPC variants. 2007-06-22 14:58:04 +02:00
traps.c cpu/m*: Remove obsolete references to CONFIG_COMMANDS 2007-07-09 19:06:00 -05:00
upatch.c * Code cleanup: 2003-06-27 21:31:46 +00:00
video.c GCC-4.x fixes: clean up global data pointer initialization for all boards. 2006-03-31 18:32:53 +02:00
wlkbd.c Initial revision 2002-08-27 09:48:53 +00:00