Skip to content

Commit bd90abf

Browse files
jw14812mcb30
authored andcommitted
[bnxt] Allocate TX rings with firmware input
Use queue_id value retrieved from firmware unconditionally when allocating TX rings. Signed-off by: Joseph Wong <[email protected]>
1 parent 77cc3ed commit bd90abf

File tree

2 files changed

+1
-2
lines changed

2 files changed

+1
-2
lines changed

src/drivers/net/bnxt/bnxt.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -1840,7 +1840,7 @@ static int bnxt_hwrm_ring_alloc ( struct bnxt *bp, u8 type )
18401840
req->page_size = LM_PAGE_BITS ( 8 );
18411841
req->int_mode = RING_ALLOC_REQ_INT_MODE_POLL;
18421842
req->length = ( u32 )bp->tx.ring_cnt;
1843-
req->queue_id = TX_RING_QID;
1843+
req->queue_id = ( u16 )bp->queue_id;
18441844
req->stat_ctx_id = ( u32 )bp->stat_ctx_id;
18451845
req->cmpl_ring_id = bp->cq_ring_id;
18461846
req->page_tbl_addr = virt_to_bus ( bp->tx.bd_virt );

src/drivers/net/bnxt/bnxt.h

-1
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,6 @@ union dma_addr64_t {
178178
RX_MASK_ACCEPT_MULTICAST)
179179
#define MAX_NQ_DESC_CNT 64
180180
#define NQ_RING_BUFFER_SIZE (MAX_NQ_DESC_CNT * sizeof(struct cmpl_base))
181-
#define TX_RING_QID (FLAG_TEST(bp->flags, BNXT_FLAG_IS_CHIP_P5_PLUS) ? (u16)bp->queue_id : ((u16)bp->port_idx * 10))
182181
#define RX_RING_QID (FLAG_TEST(bp->flags, BNXT_FLAG_IS_CHIP_P5_PLUS) ? bp->queue_id : 0)
183182
#define STAT_CTX_ID ((bp->vf || FLAG_TEST(bp->flags, BNXT_FLAG_IS_CHIP_P5_PLUS)) ? bp->stat_ctx_id : 0)
184183
#define TX_AVAIL(r) (r - 1)

0 commit comments

Comments
 (0)