Skip to content

Commit

Permalink
e100: Fix MDIO/MDIO-X
Browse files Browse the repository at this point in the history
MDIO/MDIO-X was broken due to a wrong errata. Removing the workaround
code fixes for affected NICs.

Signed-off-by: Jeff Kirsher <[email protected]>
Signed-off-by: Auke Kok <[email protected]>
  • Loading branch information
Jeff Kirsher authored and Auke Kok committed Aug 16, 2006
1 parent 09e590e commit 60ffa47
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions drivers/net/e100.c
Original file line number Diff line number Diff line change
Expand Up @@ -1391,15 +1391,11 @@ static int e100_phy_init(struct nic *nic)
}

if((nic->mac >= mac_82550_D102) || ((nic->flags & ich) &&
(mdio_read(netdev, nic->mii.phy_id, MII_TPISTATUS) & 0x8000))) {
/* enable/disable MDI/MDI-X auto-switching.
MDI/MDI-X auto-switching is disabled for 82551ER/QM chips */
if((nic->mac == mac_82551_E) || (nic->mac == mac_82551_F) ||
(nic->mac == mac_82551_10) || (nic->mii.force_media) ||
!(nic->eeprom[eeprom_cnfg_mdix] & eeprom_mdix_enabled))
mdio_write(netdev, nic->mii.phy_id, MII_NCONFIG, 0);
else
mdio_write(netdev, nic->mii.phy_id, MII_NCONFIG, NCONFIG_AUTO_SWITCH);
(mdio_read(netdev, nic->mii.phy_id, MII_TPISTATUS) & 0x8000) &&
!(nic->eeprom[eeprom_cnfg_mdix] & eeprom_mdix_enabled))) {
/* enable/disable MDI/MDI-X auto-switching. */
mdio_write(netdev, nic->mii.phy_id, MII_NCONFIG,
nic->mii.force_media ? 0 : NCONFIG_AUTO_SWITCH);
}

return 0;
Expand Down

0 comments on commit 60ffa47

Please sign in to comment.