[PATCH] net/bnxt: remove redundant NULL checks in RX path
Evgeny Sokolov
Evgeny.Sokolov at infotecs.ru
Tue Sep 15 10:47:38 CEST 2026
From: Sokolov Evgeny <Evgeny.Sokolov at infotecs.ru>
rxbd and rx_buf are assigned the addresses of array elements, which
cannot be NULL.
Remove the redundant NULL checks from the jumbo frame receive path.
Found by InfoTeCS on behalf of Linux Verification Center (linuxtesting.org) with SVACE.
Signed-off-by: Sokolov Evgeny <Evgeny.Sokolov at infotecs.ru>
---
drivers/net/bnxt/bnxt_rxr.c | 9 ---------
1 file changed, 9 deletions(-)
diff --git a/drivers/net/bnxt/bnxt_rxr.c b/drivers/net/bnxt/bnxt_rxr.c
index 0fab4ddf78..98bdbc136a 100644
--- a/drivers/net/bnxt/bnxt_rxr.c
+++ b/drivers/net/bnxt/bnxt_rxr.c
@@ -74,15 +74,6 @@ static inline int bnxt_alloc_ag_data(struct bnxt_rx_queue *rxq,
rxbd = &rxr->ag_desc_ring[prod];
rx_buf = &rxr->ag_buf_ring[prod];
- if (rxbd == NULL) {
- PMD_DRV_LOG_LINE(ERR, "Jumbo Frame. rxbd is NULL");
- return -EINVAL;
- }
-
- if (rx_buf == NULL) {
- PMD_DRV_LOG_LINE(ERR, "Jumbo Frame. rx_buf is NULL");
- return -EINVAL;
- }
mbuf = __bnxt_alloc_rx_data(rxq->agg_mb_pool);
if (!mbuf) {
--
2.30.2
More information about the stable
mailing list