igb: Change to use statically allocated array for MSIx entries
[deliverable/linux.git] / drivers / net / ethernet / intel / igb / igb_ethtool.c
index 1c7d2381af8c626e7f5175223597257c323be2ba..1df02378de6949ddf5fd11aff02548ba2fba6625 100644 (file)
@@ -1386,7 +1386,7 @@ static int igb_intr_test(struct igb_adapter *adapter, u64 *data)
        *data = 0;
 
        /* Hook up test interrupt handler just for this test */
-       if (adapter->msix_entries) {
+       if (adapter->flags & IGB_FLAG_HAS_MSIX) {
                if (request_irq(adapter->msix_entries[0].vector,
                                igb_test_intr, 0, netdev->name, adapter)) {
                        *data = 1;
@@ -1519,7 +1519,7 @@ static int igb_intr_test(struct igb_adapter *adapter, u64 *data)
        msleep(10);
 
        /* Unhook test interrupt handler */
-       if (adapter->msix_entries)
+       if (adapter->flags & IGB_FLAG_HAS_MSIX)
                free_irq(adapter->msix_entries[0].vector, adapter);
        else
                free_irq(irq, adapter);
@@ -2933,7 +2933,7 @@ static void igb_get_channels(struct net_device *netdev,
        ch->max_combined = igb_max_channels(adapter);
 
        /* Report info for other vector */
-       if (adapter->msix_entries) {
+       if (adapter->flags & IGB_FLAG_HAS_MSIX) {
                ch->max_other = NON_Q_VECTORS;
                ch->other_count = NON_Q_VECTORS;
        }
This page took 0.026405 seconds and 5 git commands to generate.