summaryrefslogtreecommitdiff
path: root/drivers/net/bnx2.h
diff options
context:
space:
mode:
authorMichael Chan <mchan@broadcom.com>2010-07-19 18:15:03 +0400
committerDavid S. Miller <davem@davemloft.net>2010-07-20 07:30:06 +0400
commit379b39a2ad613745bfbfe80256957d19689b7b94 (patch)
treedba8eff16c8a78aa38c5408250fbf001576d323c /drivers/net/bnx2.h
parent6fdae995557f0ad16320951593d6f8f48f57c14a (diff)
downloadlinux-379b39a2ad613745bfbfe80256957d19689b7b94.tar.xz
bnx2: Call pci_enable_msix() with actual number of vectors.
Based on original patch by Breno Leitão <leitao@linux.vnet.ibm.com>. Allocate the actual number of vectors and make use of fewer vectors if pci_enable_msix() returns > 0. We must allocate one additional vector for the cnic driver. Cc: Breno Leitão <leitao@linux.vnet.ibm.com> Reviewed-by: Benjamin Li <benli@broadcom.com> Reviewed-by: Matt Carlson <mcarlson@broadcom.com> Signed-off-by: Michael Chan <mchan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/bnx2.h')
-rw-r--r--drivers/net/bnx2.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/net/bnx2.h b/drivers/net/bnx2.h
index b9af6bcef894..2104c1005d02 100644
--- a/drivers/net/bnx2.h
+++ b/drivers/net/bnx2.h
@@ -6637,9 +6637,12 @@ struct flash_spec {
#define BNX2_MAX_MSIX_HW_VEC 9
#define BNX2_MAX_MSIX_VEC 9
-#define BNX2_BASE_VEC 0
-#define BNX2_TX_VEC 1
-#define BNX2_TX_INT_NUM (BNX2_TX_VEC << BNX2_PCICFG_INT_ACK_CMD_INT_NUM_SHIFT)
+#ifdef BCM_CNIC
+#define BNX2_MIN_MSIX_VEC 2
+#else
+#define BNX2_MIN_MSIX_VEC 1
+#endif
+
struct bnx2_irq {
irq_handler_t handler;