bnxt_en: Add helper functions to get firmware CP ring ID.
authorMichael Chan <michael.chan@broadcom.com>
Sun, 14 Oct 2018 11:02:50 +0000 (07:02 -0400)
committerDavid S. Miller <davem@davemloft.net>
Tue, 16 Oct 2018 05:44:32 +0000 (22:44 -0700)
commit2c61d2117ecb065aaad9e9ea9bc8bc4a6c30ec24
treeee6c1c1805a8b53f900abfbf93de00d75cd43033
parent50e3ab7836b5efdc25e935316b3a156de3ff972e
bnxt_en: Add helper functions to get firmware CP ring ID.

On the new 57500 chips, getting the associated CP ring ID associated with
an RX ring or TX ring is different than before.  On the legacy chips,
we find the associated ring group and look up the CP ring ID.  On the
57500 chips, each RX ring and TX ring has a dedicated CP ring even if
they share the MSIX.  Use these helper functions at appropriate places
to get the CP ring ID.

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