ixgbe: make q_vectors dynamic to reduce netdev size
Currently the q_vectors are being allocated statically inside of the adapter struct. This increases the overall size of the adapter struct when we can easily allocate the vectors dynamically. This patch changes that behavior so that the q_vectors are allocated dynamically and the napi structures are automatically allocated inside of the q_vectors as needed. 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>
This commit is contained in:
committed by
David S. Miller
parent
dcb4ea2ea2
commit
7a921c9362
@@ -1114,7 +1114,7 @@ static int ixgbe_set_coalesce(struct net_device *netdev,
|
||||
}
|
||||
|
||||
for (i = 0; i < adapter->num_msix_vectors - NON_Q_VECTORS; i++) {
|
||||
struct ixgbe_q_vector *q_vector = &adapter->q_vector[i];
|
||||
struct ixgbe_q_vector *q_vector = adapter->q_vector[i];
|
||||
if (q_vector->txr_count && !q_vector->rxr_count)
|
||||
/* tx vector gets half the rate */
|
||||
q_vector->eitr = (adapter->eitr_param >> 1);
|
||||
|
||||
Reference in New Issue
Block a user