summaryrefslogtreecommitdiff
path: root/drivers/net/sfc/mdio_10g.c
diff options
context:
space:
mode:
authorSteve Hodgson <shodgson@solarflare.com>2009-01-29 20:49:09 +0300
committerDavid S. Miller <davem@davemloft.net>2009-01-31 01:06:29 +0300
commit8b9dc8dd447cfe27c0214761ced22a8e4aa58f5e (patch)
tree2b7eb0523fe541647ca2e78f6c4c0742700c7959 /drivers/net/sfc/mdio_10g.c
parent2d18835d65b7433e7e6583f65395f8c01e7874af (diff)
downloadlinux-8b9dc8dd447cfe27c0214761ced22a8e4aa58f5e.tar.xz
sfc: SFT9001: Fix speed reporting in 1G PHY loopback
Instead of disabling AN in loopback, just prevent restarting AN and override the speed in sft9001_get_settings(). Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/sfc/mdio_10g.c')
-rw-r--r--drivers/net/sfc/mdio_10g.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/sfc/mdio_10g.c b/drivers/net/sfc/mdio_10g.c
index f6a16428113d..7f09ab581945 100644
--- a/drivers/net/sfc/mdio_10g.c
+++ b/drivers/net/sfc/mdio_10g.c
@@ -15,6 +15,7 @@
#include "net_driver.h"
#include "mdio_10g.h"
#include "boards.h"
+#include "workarounds.h"
int mdio_clause45_reset_mmd(struct efx_nic *port, int mmd,
int spins, int spintime)
@@ -517,6 +518,9 @@ int mdio_clause45_set_settings(struct efx_nic *efx,
reg |= BMCR_ANENABLE | BMCR_ANRESTART;
else
reg &= ~BMCR_ANENABLE;
+ if (EFX_WORKAROUND_15195(efx)
+ && LOOPBACK_MASK(efx) & efx->phy_op->loopbacks)
+ reg &= ~BMCR_ANRESTART;
if (xnp)
reg |= 1 << MDIO_AN_CTRL_XNP_LBN;
else