[PATCH 03/11] net/bnxt: fix Rx handler
Ajit Khaparde
ajit.khaparde at broadcom.com
Wed Feb 5 18:19:56 CET 2025
Fix the code accounting the status of compressed CQE handler.
The code was inside the block handling the normal CQE mode.
Moved the code out. Without this the Rx datapath was broken
for compressed CQEs in scalar mode.
Fixes: 5c980062d895 ("net/bnxt: support compressed Rx CQE")
Cc: stable at dpdk.org
Signed-off-by: Ajit Khaparde <ajit.khaparde at broadcom.com>
---
drivers/net/bnxt/bnxt_rxr.c | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/drivers/net/bnxt/bnxt_rxr.c b/drivers/net/bnxt/bnxt_rxr.c
index 5b43bcbea6..b53d9a917a 100644
--- a/drivers/net/bnxt/bnxt_rxr.c
+++ b/drivers/net/bnxt/bnxt_rxr.c
@@ -1390,14 +1390,6 @@ uint16_t bnxt_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,
} else if ((CMP_TYPE(rxcmp) >= CMPL_BASE_TYPE_RX_TPA_START_V2) &&
(CMP_TYPE(rxcmp) <= CMPL_BASE_TYPE_RX_TPA_START_V3)) {
rc = bnxt_rx_pkt(&rx_pkts[nb_rx_pkts], rxq, &raw_cons);
- if (!rc)
- nb_rx_pkts++;
- else if (rc == -EBUSY) /* partial completion */
- break;
- else if (rc == -ENODEV) /* completion for representor */
- nb_rep_rx_pkts++;
- else if (rc == -ENOMEM)
- nb_rx_pkts++;
} else if (!BNXT_NUM_ASYNC_CPR(rxq->bp)) {
evt =
bnxt_event_hwrm_resp_handler(rxq->bp,
@@ -1407,6 +1399,14 @@ uint16_t bnxt_recv_pkts(void *rx_queue, struct rte_mbuf **rx_pkts,
goto done;
}
+ if (!rc)
+ nb_rx_pkts++;
+ else if (rc == -EBUSY) /* partial completion */
+ break;
+ else if (rc == -ENODEV) /* completion for representor */
+ nb_rep_rx_pkts++;
+ else if (rc == -ENOMEM)
+ nb_rx_pkts++;
raw_cons = NEXT_RAW_CMP(raw_cons);
/*
* The HW reposting may fall behind if mbuf allocation has
--
2.39.5 (Apple Git-154)
More information about the stable
mailing list