]> git.baikalelectronics.ru Git - kernel.git/commit
bnxt_en: Fix _bnxt_get_max_rings() for 57500 chips.
authorMichael Chan <michael.chan@broadcom.com>
Sun, 9 Dec 2018 12:01:02 +0000 (07:01 -0500)
committerDavid S. Miller <davem@davemloft.net>
Sun, 9 Dec 2018 19:46:58 +0000 (11:46 -0800)
commitea80c546dfe1972b6d09eaac1dba8bd0a6278af5
treea2196f1b3b09898c84e09abcc2be33e804da4368
parent48fffa55adbcabd8606738081a78dc53a70cbe30
bnxt_en: Fix _bnxt_get_max_rings() for 57500 chips.

The CP rings are accounted differently on the new 57500 chips.  There
must be enough CP rings for the sum of RX and TX rings on the new
chips.  The current logic may be over-estimating the RX and TX rings.

The output parameter max_cp should be the maximum NQs capped by
MSIX vectors available for networking in the context of 57500 chips.
The existing code which uses CMPL rings capped by the MSIX vectors
works most of the time but is not always correct.

Signed-off-by: Michael Chan <michael.chan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/bnxt/bnxt.c