OSDN Git Service

igb: Fix NULL assignment to incorrect variable in igb_reset_q_vector
authorToshiaki Makita <makita.toshiaki@lab.ntt.co.jp>
Mon, 13 Apr 2015 09:15:11 +0000 (18:15 +0900)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Thu, 7 May 2015 12:11:29 +0000 (05:11 -0700)
adapter->tx_ring is set to NULL where rx_ring should be.

Fixes: 5536d2102a2d ("igb: Combine q_vector and ring allocation into a single function")
Signed-off-by: Toshiaki Makita <makita.toshiaki@lab.ntt.co.jp>
Tested-by: Aaron Brown <aaron.f.brown@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/igb/igb_main.c

index 783d60e..a0a9b1f 100644 (file)
@@ -1036,7 +1036,7 @@ static void igb_reset_q_vector(struct igb_adapter *adapter, int v_idx)
                adapter->tx_ring[q_vector->tx.ring->queue_index] = NULL;
 
        if (q_vector->rx.ring)
-               adapter->tx_ring[q_vector->rx.ring->queue_index] = NULL;
+               adapter->rx_ring[q_vector->rx.ring->queue_index] = NULL;
 
        netif_napi_del(&q_vector->napi);