aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ixgbe
diff options
context:
space:
mode:
authorMallikarjuna R Chilakala <mallikarjuna.chilakala@intel.com>2009-11-23 13:45:11 -0500
committerDavid S. Miller <davem@davemloft.net>2009-11-23 13:45:11 -0500
commitedd2ea5559737e5239d5c80fa1a55b8bc440470b (patch)
treeaf6babaa0766b89b44e303bdae290ca3026f634b /drivers/net/ixgbe
parent94b982b2e4be9661fe1c3893aa780a711b09cd30 (diff)
ixgbe: Use rx buffer length from rx ring for configuring rscctl
While configuring rscctl use rx buffer length from rx ring structure instead of passing rx_buf_len to ixgbe_configure_rscctl Signed-off-by: Mallikarjuna R Chilakala <mallikarjuna.chilakala@intel.com> Acked-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@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')
-rw-r--r--drivers/net/ixgbe/ixgbe_main.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/ixgbe/ixgbe_main.c b/drivers/net/ixgbe/ixgbe_main.c
index ffd1f1639706..a3a2a9a3df81 100644
--- a/drivers/net/ixgbe/ixgbe_main.c
+++ b/drivers/net/ixgbe/ixgbe_main.c
@@ -2066,18 +2066,18 @@ static u32 ixgbe_setup_mrqc(struct ixgbe_adapter *adapter)
2066 * ixgbe_configure_rscctl - enable RSC for the indicated ring 2066 * ixgbe_configure_rscctl - enable RSC for the indicated ring
2067 * @adapter: address of board private structure 2067 * @adapter: address of board private structure
2068 * @index: index of ring to set 2068 * @index: index of ring to set
2069 * @rx_buf_len: rx buffer length
2070 **/ 2069 **/
2071static void ixgbe_configure_rscctl(struct ixgbe_adapter *adapter, int index, 2070static void ixgbe_configure_rscctl(struct ixgbe_adapter *adapter, int index)
2072 int rx_buf_len)
2073{ 2071{
2074 struct ixgbe_ring *rx_ring; 2072 struct ixgbe_ring *rx_ring;
2075 struct ixgbe_hw *hw = &adapter->hw; 2073 struct ixgbe_hw *hw = &adapter->hw;
2076 int j; 2074 int j;
2077 u32 rscctrl; 2075 u32 rscctrl;
2076 int rx_buf_len;
2078 2077
2079 rx_ring = &adapter->rx_ring[index]; 2078 rx_ring = &adapter->rx_ring[index];
2080 j = rx_ring->reg_idx; 2079 j = rx_ring->reg_idx;
2080 rx_buf_len = rx_ring->rx_buf_len;
2081 rscctrl = IXGBE_READ_REG(hw, IXGBE_RSCCTL(j)); 2081 rscctrl = IXGBE_READ_REG(hw, IXGBE_RSCCTL(j));
2082 rscctrl |= IXGBE_RSCCTL_RSCEN; 2082 rscctrl |= IXGBE_RSCCTL_RSCEN;
2083 /* 2083 /*
@@ -2285,7 +2285,7 @@ static void ixgbe_configure_rx(struct ixgbe_adapter *adapter)
2285 if (adapter->flags2 & IXGBE_FLAG2_RSC_ENABLED) { 2285 if (adapter->flags2 & IXGBE_FLAG2_RSC_ENABLED) {
2286 /* Enable 82599 HW-RSC */ 2286 /* Enable 82599 HW-RSC */
2287 for (i = 0; i < adapter->num_rx_queues; i++) 2287 for (i = 0; i < adapter->num_rx_queues; i++)
2288 ixgbe_configure_rscctl(adapter, i, rx_buf_len); 2288 ixgbe_configure_rscctl(adapter, i);
2289 2289
2290 /* Disable RSC for ACK packets */ 2290 /* Disable RSC for ACK packets */
2291 IXGBE_WRITE_REG(hw, IXGBE_RSCDBU, 2291 IXGBE_WRITE_REG(hw, IXGBE_RSCDBU,