Call efx_set_channels() before efx->type->dimension_resources()
authorDaniel Pieczko <dpieczko@solarflare.com>
Tue, 1 Apr 2014 12:10:34 +0000 (13:10 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 14 Apr 2014 13:50:04 +0000 (06:50 -0700)
commit98fa11217eb8362e6a87e8c608595e97ff90342d
tree831c9ea22a41fb194fc462d2a03fa046c485f93d
parent7caaadd87daa11474872b63ff4edf745c6cb8550
Call efx_set_channels() before efx->type->dimension_resources()

[ Upstream commit 52ad762b85ed7947ec9eff6b036eb985352f6874 ]

When using the "separate_tx_channels=1" module parameter, the TX queues are
initially numbered starting from the first TX-only channel number (after all the
RX-only channels).  efx_set_channels() renumbers the queues so that they are
indexed from zero.

On EF10, the TX queues need to be relabelled in this way before calling the
dimension_resources NIC type operation, otherwise the TX queue PIO buffers can be
linked to the wrong VIs when using "separate_tx_channels=1".

Added comments to explain UC/WC mappings for PIO buffers

Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/ethernet/sfc/ef10.c
drivers/net/ethernet/sfc/efx.c