With respect to the Intel EP80579 (Tolapai) chipset, there is an issue in the 
iegbe Ethernet driver that may affect some boards with this chipset. Perhaps 
some background information is in order.

This chipset (actually a SoC) has three built in Ethernet MACs. OEMs may add up 
to three PHYs. Logically it makes sense to have MACs and PHYs mapped 1:1, eg 
MAC 0 -> PHY 0 
MAC 1 -> PHY 1 
MAC 2 -> PHY 2

Indeed, this is how it's done in the pristine sources released by Intel at 
http://www.intel.com/design/intarch/ep80579/sw_tools.htm

But OpenWRT uses base sources released by ADI Engineering for their Ocracoke 
Island SBC at 
ftp://ftp.adiengineering.com/Archive/OcracokeIsland/Drivers/Linux/1.0.34/Embedded.L.1.0.34.ADI.R100.tar.gz.
 See https://dev.openwrt.org/browser/trunk/package/ep80579-drivers/Makefile. In 
this release the mapping has been changed, possibly to work around a mistake in 
how they wired up their board:
MAC 0 -> PHY 1
MAC 1 -> PHY 2
MAC 2 -> PHY 0

This obviously wreaks havoc with correctly designed EP80579 systems like mine.

This patch reverts the MAC/PHY mapping back to the original. Of course it might 
break some boards that relied on the miswired version. Ideally there would be 
some sort of way to detect the correct mac/phy map, but that's beyond me.

Thanks for keeping this driver patched for the newer kernels.

Signed-off-by: Jeff Laughlin <jlaugh...@northernpower.com>

diff -r fc19757418a2 -r bf3ef1d3f391 iegbe_oem_phy.c
--- a/Embedded/src/GbE/iegbe_oem_phy.c  Tue Dec 14 10:49:26 2010 -0500
+++ b/Embedded/src/GbE/iegbe_oem_phy.c  Tue Dec 14 10:59:22 2010 -0500
@@ -889,14 +889,14 @@
        switch(device_number)
     {
       case ICP_XXXX_MAC_0: 
+             hw->phy_addr = 0x00;
+         break;
+      case ICP_XXXX_MAC_1: 
              hw->phy_addr = 0x01;
          break;
-      case ICP_XXXX_MAC_1: 
+      case ICP_XXXX_MAC_2: 
              hw->phy_addr = 0x02;
          break;
-      case ICP_XXXX_MAC_2: 
-             hw->phy_addr = 0x00;
-         break;
          default:  hw->phy_addr = 0x00;
     }
      return hw->phy_addr;
_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel

Reply via email to