diff options
author | Alexander Duyck <alexander.h.duyck@intel.com> | 2010-08-19 09:37:48 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-08-19 19:44:22 -0400 |
commit | 826437d3de43174a8199776b5c1178bafa0b6634 (patch) | |
tree | 80d704a2d473bede0cbfe551a2f100f14db71e6e /drivers | |
parent | 1395807091300b84789316cad2a9142b58f9092a (diff) |
ixgbe: remove redundant configuration of vmolr, rename generic variable
The vmolr is configured already in ixgbe_set_rx_mode for the PF so there is
no need to set it again in ixgbe_configure_rx.
Instead of using the variable name reg, it is easier to just rename it to
gcr_ext to reflect the register contents that the variable holds.
Signed-off-by: Alexander Duyck <alexander.h.duyck@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')
-rw-r--r-- | drivers/net/ixgbe/ixgbe_main.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/drivers/net/ixgbe/ixgbe_main.c b/drivers/net/ixgbe/ixgbe_main.c index b7553643f9ad..520b95fc4d41 100644 --- a/drivers/net/ixgbe/ixgbe_main.c +++ b/drivers/net/ixgbe/ixgbe_main.c | |||
@@ -2709,7 +2709,7 @@ static void ixgbe_configure_rx(struct ixgbe_adapter *adapter) | |||
2709 | int max_frame = netdev->mtu + ETH_HLEN + ETH_FCS_LEN; | 2709 | int max_frame = netdev->mtu + ETH_HLEN + ETH_FCS_LEN; |
2710 | int i; | 2710 | int i; |
2711 | u32 rxctrl; | 2711 | u32 rxctrl; |
2712 | u32 hlreg0; | 2712 | u32 hlreg0, gcr_ext; |
2713 | u32 rdrxctl; | 2713 | u32 rdrxctl; |
2714 | int rx_buf_len; | 2714 | int rx_buf_len; |
2715 | 2715 | ||
@@ -2813,24 +2813,21 @@ static void ixgbe_configure_rx(struct ixgbe_adapter *adapter) | |||
2813 | IXGBE_WRITE_REG(hw, IXGBE_VFRE(reg_offset), (1 << vf_shift)); | 2813 | IXGBE_WRITE_REG(hw, IXGBE_VFRE(reg_offset), (1 << vf_shift)); |
2814 | IXGBE_WRITE_REG(hw, IXGBE_VFTE(reg_offset), (1 << vf_shift)); | 2814 | IXGBE_WRITE_REG(hw, IXGBE_VFTE(reg_offset), (1 << vf_shift)); |
2815 | IXGBE_WRITE_REG(hw, IXGBE_PFDTXGSWC, IXGBE_PFDTXGSWC_VT_LBEN); | 2815 | IXGBE_WRITE_REG(hw, IXGBE_PFDTXGSWC, IXGBE_PFDTXGSWC_VT_LBEN); |
2816 | ixgbe_set_vmolr(hw, adapter->num_vfs, true); | ||
2817 | } | 2816 | } |
2818 | 2817 | ||
2819 | /* Program MRQC for the distribution of queues */ | 2818 | /* Program MRQC for the distribution of queues */ |
2820 | ixgbe_setup_mrqc(adapter); | 2819 | ixgbe_setup_mrqc(adapter); |
2821 | 2820 | ||
2822 | if (adapter->num_vfs) { | 2821 | if (adapter->num_vfs) { |
2823 | u32 reg; | ||
2824 | |||
2825 | /* Map PF MAC address in RAR Entry 0 to first pool | 2822 | /* Map PF MAC address in RAR Entry 0 to first pool |
2826 | * following VFs */ | 2823 | * following VFs */ |
2827 | hw->mac.ops.set_vmdq(hw, 0, adapter->num_vfs); | 2824 | hw->mac.ops.set_vmdq(hw, 0, adapter->num_vfs); |
2828 | 2825 | ||
2829 | /* Set up VF register offsets for selected VT Mode, i.e. | 2826 | /* Set up VF register offsets for selected VT Mode, i.e. |
2830 | * 64 VFs for SR-IOV */ | 2827 | * 64 VFs for SR-IOV */ |
2831 | reg = IXGBE_READ_REG(hw, IXGBE_GCR_EXT); | 2828 | gcr_ext = IXGBE_READ_REG(hw, IXGBE_GCR_EXT); |
2832 | reg |= IXGBE_GCR_EXT_SRIOV; | 2829 | gcr_ext |= IXGBE_GCR_EXT_SRIOV; |
2833 | IXGBE_WRITE_REG(hw, IXGBE_GCR_EXT, reg); | 2830 | IXGBE_WRITE_REG(hw, IXGBE_GCR_EXT, gcr_ext); |
2834 | } | 2831 | } |
2835 | 2832 | ||
2836 | if (hw->mac.type == ixgbe_mac_82599EB) { | 2833 | if (hw->mac.type == ixgbe_mac_82599EB) { |