Skip to content

Commit b1a0c97

Browse files
michalQbanguy11
authored andcommitted
ice: fix incorrect counter for buffer allocation failures
Currently, the driver increments `alloc_page_failed` when buffer allocation fails in `ice_clean_rx_irq()`. However, this counter is intended for page allocation failures, not buffer allocation issues. This patch corrects the counter by incrementing `alloc_buf_failed` instead, ensuring accurate statistics reporting for buffer allocation failures. Fixes: 2fba7dc ("ice: Add support for XDP multi-buffer on Rx side") Reported-by: Jacob Keller <[email protected]> Suggested-by: Paul Menzel <[email protected]> Signed-off-by: Michal Kubiak <[email protected]> Reviewed-by: Paul Menzel <[email protected]> Reviewed-by: Jason Xing <[email protected]> Reviewed-by: Aleksandr Loktionov <[email protected]> Tested-by: Priya Singh <[email protected]> Signed-off-by: Tony Nguyen <[email protected]>
1 parent 5c5e5b5 commit b1a0c97

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/net/ethernet/intel/ice/ice_txrx.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1352,7 +1352,7 @@ static int ice_clean_rx_irq(struct ice_rx_ring *rx_ring, int budget)
13521352
skb = ice_construct_skb(rx_ring, xdp);
13531353
/* exit if we failed to retrieve a buffer */
13541354
if (!skb) {
1355-
rx_ring->ring_stats->rx_stats.alloc_page_failed++;
1355+
rx_ring->ring_stats->rx_stats.alloc_buf_failed++;
13561356
xdp_verdict = ICE_XDP_CONSUMED;
13571357
}
13581358
ice_put_rx_mbuf(rx_ring, xdp, &xdp_xmit, ntc, xdp_verdict);

0 commit comments

Comments
 (0)