aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/sfc/falcon.c
diff options
context:
space:
mode:
authorBen Hutchings <bhutchings@solarflare.com>2008-05-07 08:36:19 -0400
committerJeff Garzik <jgarzik@redhat.com>2008-05-13 01:31:44 -0400
commit3273c2e8c66a21ae1c53b0c730ee937c6efde7e2 (patch)
treeee2a1f187c0310e229f51fbfc5fbbe7a5fce5b76 /drivers/net/sfc/falcon.c
parent05e3ec04460180f48810cddc2f78e80a725657ad (diff)
[netdrvr] sfc: sfc: Add self-test support
Add a set of self-tests accessible thorugh ethtool. Add hardware loopback and TX disable control code to support them. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'drivers/net/sfc/falcon.c')
-rw-r--r--drivers/net/sfc/falcon.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/net/sfc/falcon.c b/drivers/net/sfc/falcon.c
index 247629cee5aa..b57cc68058c0 100644
--- a/drivers/net/sfc/falcon.c
+++ b/drivers/net/sfc/falcon.c
@@ -1732,7 +1732,8 @@ void falcon_drain_tx_fifo(struct efx_nic *efx)
1732 efx_oword_t temp; 1732 efx_oword_t temp;
1733 int count; 1733 int count;
1734 1734
1735 if (FALCON_REV(efx) < FALCON_REV_B0) 1735 if ((FALCON_REV(efx) < FALCON_REV_B0) ||
1736 (efx->loopback_mode != LOOPBACK_NONE))
1736 return; 1737 return;
1737 1738
1738 falcon_read(efx, &temp, MAC0_CTRL_REG_KER); 1739 falcon_read(efx, &temp, MAC0_CTRL_REG_KER);
@@ -2092,6 +2093,8 @@ static int falcon_probe_phy(struct efx_nic *efx)
2092 efx->phy_type); 2093 efx->phy_type);
2093 return -1; 2094 return -1;
2094 } 2095 }
2096
2097 efx->loopback_modes = LOOPBACKS_10G_INTERNAL | efx->phy_op->loopbacks;
2095 return 0; 2098 return 0;
2096} 2099}
2097 2100