bnx2x: limit number of interrupt vectors for 57711
Original straightforward division may lead to zeroing number of SB and null-pointer dereference when device is short of MSIX vectors or lacks MSIX capabilities. Reported-by: Vladislav Zolotarov <vladz@cloudius-systems.com> Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com> Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com> Signed-off-by: Ariel Elior <ariele@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
a02bdd423d
commit
e848582cee
@@ -2499,4 +2499,6 @@ void bnx2x_set_local_cmng(struct bnx2x *bp);
|
||||
#define MCPR_SCRATCH_BASE(bp) \
|
||||
(CHIP_IS_E1x(bp) ? MCP_REG_MCPR_SCRATCH : MCP_A_REG_MCPR_SCRATCH)
|
||||
|
||||
#define E1H_MAX_MF_SB_COUNT (HC_SB_MAX_SB_E1X/(E1HVN_MAX * PORT_MAX))
|
||||
|
||||
#endif /* bnx2x.h */
|
||||
|
Reference in New Issue
Block a user