Skip to content

Commit

Permalink
ixgbe: Remove unneeded register writes in VF VLAN setup
Browse files Browse the repository at this point in the history
The driver is unnecessarily writing values to VLAN control registers.
These writes already done elsewhere and are superfluous here.

Signed-off-by: Greg Rose <gregory.v.rose@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Greg Rose authored and David S. Miller committed May 6, 2010
1 parent 58544fe commit 7342291
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions drivers/net/ixgbe/ixgbe_sriov.c
Original file line number Diff line number Diff line change
Expand Up @@ -98,17 +98,6 @@ void ixgbe_restore_vf_multicasts(struct ixgbe_adapter *adapter)

int ixgbe_set_vf_vlan(struct ixgbe_adapter *adapter, int add, int vid, u32 vf)
{
u32 ctrl;

/* Check if global VLAN already set, if not set it */
ctrl = IXGBE_READ_REG(&adapter->hw, IXGBE_VLNCTRL);
if (!(ctrl & IXGBE_VLNCTRL_VFE)) {
/* enable VLAN tag insert/strip */
ctrl |= IXGBE_VLNCTRL_VFE;
ctrl &= ~IXGBE_VLNCTRL_CFIEN;
IXGBE_WRITE_REG(&adapter->hw, IXGBE_VLNCTRL, ctrl);
}

return adapter->hw.mac.ops.set_vfta(&adapter->hw, vid, vf, (bool)add);
}

Expand Down

0 comments on commit 7342291

Please sign in to comment.