diff options
author | Emil Tantilov <emil.s.tantilov@intel.com> | 2010-05-13 13:33:00 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-05-14 00:07:32 -0400 |
commit | e433ea1fb03c10debf101019668b83abed041c24 (patch) | |
tree | e337d64fc7be738c1220b0e66fa4c1e5a5f4c552 /drivers/net/ixgbe/ixgbe_common.c | |
parent | e7874c996b8591f59d78efa519031dab5b58723b (diff) |
ixgbe: fix setting of promisc mode when using mac-vlans
Introduce uc_set_promisc flag to fix enabling of promisc mode
when exceeding the number of supported RAR entries.
Issue discovered by Ben Greear when using mac-vlans.
Reported-by: Ben Greear <greearb@candelatech.com>
Signed-off-by: Emil Tantilov <emil.s.tantilov@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ixgbe/ixgbe_common.c')
-rw-r--r-- | drivers/net/ixgbe/ixgbe_common.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/net/ixgbe/ixgbe_common.c b/drivers/net/ixgbe/ixgbe_common.c index 6eb5814ca7da..753f2ab39d7f 100644 --- a/drivers/net/ixgbe/ixgbe_common.c +++ b/drivers/net/ixgbe/ixgbe_common.c | |||
@@ -1392,14 +1392,17 @@ s32 ixgbe_update_uc_addr_list_generic(struct ixgbe_hw *hw, | |||
1392 | fctrl = IXGBE_READ_REG(hw, IXGBE_FCTRL); | 1392 | fctrl = IXGBE_READ_REG(hw, IXGBE_FCTRL); |
1393 | fctrl |= IXGBE_FCTRL_UPE; | 1393 | fctrl |= IXGBE_FCTRL_UPE; |
1394 | IXGBE_WRITE_REG(hw, IXGBE_FCTRL, fctrl); | 1394 | IXGBE_WRITE_REG(hw, IXGBE_FCTRL, fctrl); |
1395 | hw->addr_ctrl.uc_set_promisc = true; | ||
1395 | } | 1396 | } |
1396 | } else { | 1397 | } else { |
1397 | /* only disable if set by overflow, not by user */ | 1398 | /* only disable if set by overflow, not by user */ |
1398 | if (old_promisc_setting && !hw->addr_ctrl.user_set_promisc) { | 1399 | if ((old_promisc_setting && hw->addr_ctrl.uc_set_promisc) && |
1400 | !(hw->addr_ctrl.user_set_promisc)) { | ||
1399 | hw_dbg(hw, " Leaving address overflow promisc mode\n"); | 1401 | hw_dbg(hw, " Leaving address overflow promisc mode\n"); |
1400 | fctrl = IXGBE_READ_REG(hw, IXGBE_FCTRL); | 1402 | fctrl = IXGBE_READ_REG(hw, IXGBE_FCTRL); |
1401 | fctrl &= ~IXGBE_FCTRL_UPE; | 1403 | fctrl &= ~IXGBE_FCTRL_UPE; |
1402 | IXGBE_WRITE_REG(hw, IXGBE_FCTRL, fctrl); | 1404 | IXGBE_WRITE_REG(hw, IXGBE_FCTRL, fctrl); |
1405 | hw->addr_ctrl.uc_set_promisc = false; | ||
1403 | } | 1406 | } |
1404 | } | 1407 | } |
1405 | 1408 | ||