aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ixgbe/ixgbe_ethtool.c
diff options
context:
space:
mode:
authorAlexander Duyck <alexander.h.duyck@intel.com>2011-05-14 01:16:02 +0000
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>2011-06-23 22:46:37 -0700
commit1f4d51836f5e49f2e5201f1daf90239c04b3faf2 (patch)
treee6bb9cd4125067201c9ec57961ebbeecf7d912dc /drivers/net/ixgbe/ixgbe_ethtool.c
parentixgbe: disable RSC when Rx checksum is off (diff)
downloadlinux-dev-1f4d51836f5e49f2e5201f1daf90239c04b3faf2.tar.xz
linux-dev-1f4d51836f5e49f2e5201f1daf90239c04b3faf2.zip
ixgbe: fix ring assignment issues for SR-IOV and drop cases
This change fixes the fact that we would trigger a null pointer dereference or specify the wrong ring if the rings were restored. This change makes certain that the DROP queue is a static value, and all other rings are based on the ring offsets for the PF. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Ross Brattain <ross.b.brattain@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to 'drivers/net/ixgbe/ixgbe_ethtool.c')
-rw-r--r--drivers/net/ixgbe/ixgbe_ethtool.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/ixgbe/ixgbe_ethtool.c b/drivers/net/ixgbe/ixgbe_ethtool.c
index 596d7943024f..074e9baf069a 100644
--- a/drivers/net/ixgbe/ixgbe_ethtool.c
+++ b/drivers/net/ixgbe/ixgbe_ethtool.c
@@ -2677,6 +2677,8 @@ static int ixgbe_add_ethtool_fdir_entry(struct ixgbe_adapter *adapter,
/* program filters to filter memory */
err = ixgbe_fdir_write_perfect_filter_82599(hw,
&input->filter, input->sw_idx,
+ (input->action == IXGBE_FDIR_DROP_QUEUE) ?
+ IXGBE_FDIR_DROP_QUEUE :
adapter->rx_ring[input->action]->reg_idx);
if (err)
goto err_out_w_lock;