ixgbe: Refactor MSI-X allocation mechanism
Our current MSI-X allocation mechanism does not support new hardware at all. It also isn't getting the actual number of supported MSI-X vectors from the device. This patch allows the number of MSI-X vectors to be specific to a device, plus it gets the number of MSI-X vectors available from PCIe configuration space. Signed-off-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>
This commit is contained in:
committed by
David S. Miller
parent
2f21bdd354
commit
eb7f139ce5
@@ -2421,7 +2421,13 @@ static void ixgbe_acquire_msix_vectors(struct ixgbe_adapter *adapter,
|
||||
ixgbe_set_num_queues(adapter);
|
||||
} else {
|
||||
adapter->flags |= IXGBE_FLAG_MSIX_ENABLED; /* Woot! */
|
||||
adapter->num_msix_vectors = vectors;
|
||||
/*
|
||||
* Adjust for only the vectors we'll use, which is minimum
|
||||
* of max_msix_q_vectors + NON_Q_VECTORS, or the number of
|
||||
* vectors we were allocated.
|
||||
*/
|
||||
adapter->num_msix_vectors = min(vectors,
|
||||
adapter->max_msix_q_vectors + NON_Q_VECTORS);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2746,6 +2752,7 @@ static int __devinit ixgbe_sw_init(struct ixgbe_adapter *adapter)
|
||||
adapter->ring_feature[RING_F_RSS].indices = rss;
|
||||
adapter->flags |= IXGBE_FLAG_RSS_ENABLED;
|
||||
adapter->ring_feature[RING_F_DCB].indices = IXGBE_MAX_DCB_INDICES;
|
||||
adapter->max_msix_q_vectors = MAX_MSIX_Q_VECTORS_82598;
|
||||
|
||||
#ifdef CONFIG_IXGBE_DCB
|
||||
/* Configure DCB traffic classes */
|
||||
|
Reference in New Issue
Block a user