summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c
diff options
context:
space:
mode:
authorMichael Chan <michael.chan@broadcom.com>2018-03-31 13:54:16 -0400
committerDavid S. Miller <davem@davemloft.net>2018-03-31 23:24:20 -0400
commit9899bb59ff08a50aef033b4d388d223adca58a7f (patch)
treedd1a786936532c9cfa82835f08053645a90e412a /drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c
parent845adfe40c2a75e67ddae6639fc2b987338b7983 (diff)
bnxt_en: Improve ring allocation logic.
Currently, the driver code makes some assumptions about the group index and the map index of rings. This makes the code more difficult to understand and less flexible. Improve it by adding the grp_idx and map_idx fields explicitly to the bnxt_ring_struct as a union. The grp_idx is initialized for each tx ring and rx agg ring during init. time. We do the same for the map_idx for each cmpl ring. The grp_idx ties the tx ring to the ring group. The map_idx is the doorbell index of the ring. With this new infrastructure, we can change the ring index mapping scheme easily in the future. Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c')
0 files changed, 0 insertions, 0 deletions