bnxt_en: Add completion ring pointer in TX and RX ring structures
authorMichael Chan <michael.chan@broadcom.com>
Tue, 14 Nov 2023 00:16:10 +0000 (16:16 -0800)
committerDavid S. Miller <davem@davemloft.net>
Wed, 15 Nov 2023 10:07:39 +0000 (10:07 +0000)
commit7f0a168b0441ef7fd6b46563efb2706c58ac2a4c
tree051330d4553c0b4de4cbcd60842dbd3dbd448b75
parent34eec1f29a5998305578fcc3e55d491a1795b56d
bnxt_en: Add completion ring pointer in TX and RX ring structures

From the TX or RX ring structure, we need to find the corresponding
completion ring during initialization.  On P5 chips, we use the MSIX/napi
entry to locate the completion ring because there is only one RX/TX
ring per MSIX.  To allow multiple TX rings for each MSIX, we need
to add a direct pointer from the TX ring and RX ring structures.
This also simplifies the existing logic.

Reviewed-by: Andy Gospodarek <andrew.gospodarek@broadcom.com>
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
drivers/net/ethernet/broadcom/bnxt/bnxt.h
drivers/net/ethernet/broadcom/bnxt/bnxt_xdp.c