summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/sfc/ethtool.c
diff options
context:
space:
mode:
authorBen Hutchings <bhutchings@solarflare.com>2012-09-13 03:22:52 +0200
committerBen Hutchings <bhutchings@solarflare.com>2012-10-02 02:58:41 +0200
commit1ac0226eb04e56cacee080fb71938eb50b5245eb (patch)
treeb48353aaad1bbd35211aaff02d5630299b50776d /drivers/net/ethernet/sfc/ethtool.c
parentsfc: Fix MCDI structure field lookup (diff)
downloadlinux-1ac0226eb04e56cacee080fb71938eb50b5245eb.tar.xz
linux-1ac0226eb04e56cacee080fb71938eb50b5245eb.zip
sfc: Fix loopback self-test with separate_tx_channels=1
The loopback self-test iterates over all the TX queues of channel 0, which is not very interesting when that's an RX-only channel. Signed-off-by: Ben Hutchings <bhutchings@solarflre.com>
Diffstat (limited to 'drivers/net/ethernet/sfc/ethtool.c')
-rw-r--r--drivers/net/ethernet/sfc/ethtool.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/ethernet/sfc/ethtool.c b/drivers/net/ethernet/sfc/ethtool.c
index 9df556c01b8e..cf772074145a 100644
--- a/drivers/net/ethernet/sfc/ethtool.c
+++ b/drivers/net/ethernet/sfc/ethtool.c
@@ -337,7 +337,8 @@ static int efx_fill_loopback_test(struct efx_nic *efx,
unsigned int test_index,
struct ethtool_string *strings, u64 *data)
{
- struct efx_channel *channel = efx_get_channel(efx, 0);
+ struct efx_channel *channel =
+ efx_get_channel(efx, efx->tx_channel_offset);
struct efx_tx_queue *tx_queue;
efx_for_each_channel_tx_queue(tx_queue, channel) {