|SUCCESS| [v2] net/ice: fix max number of descriptors for E830

dpdklab at iol.unh.edu dpdklab at iol.unh.edu
Mon Oct 12 11:50:24 CEST 2026


Test-Label: ai-code-review
Test-Status: SUCCESS
https://dpdk.org/patch/171072

_AI Code Review_

=== Patch Review: series.patch (via Claude) ===
Review date: 2026-10-12

# DPDK Patch Review

## ERRORS

None identified.

## WARNINGS

None identified.

## INFO

### 1. Comment style and placement

**File:** `drivers/net/intel/ice/ice_rxtx.h`  
**Lines:** Comment added before `ICE_MAX_RING_DESC`

The multi-line comment uses the correct DPDK format. However, the comment placement is slightly awkward--it appears between `ICE_MIN_RING_DESC` and `ICE_MAX_RING_DESC`, yet refers to why callers should use `ICE_MAX_NUM_DESC_BY_MAC()` instead of `ICE_MAX_RING_DESC`. Consider placing it immediately before the `ICE_MAX_NUM_DESC_BY_MAC()` macro definition (after `ICE_MAX_RING_DESC_E830`) where it would be more directly associated with the code it describes.

Current:
```c
#define ICE_MIN_RING_DESC    64
/*
 * E830 needs a lower cap, so use ICE_MAX_NUM_DESC_BY_MAC() for ring
 * limits rather than ICE_MAX_RING_DESC directly.
 */
#define ICE_MAX_RING_DESC    (8192 - 32)
#define ICE_MAX_RING_DESC_E830	  8096
#define ICE_MAX_NUM_DESC_BY_MAC(hw) ...
```

Alternative (slightly better):
```c
#define ICE_MIN_RING_DESC    64
#define ICE_MAX_RING_DESC    (8192 - 32)
#define ICE_MAX_RING_DESC_E830	  8096
/*
 * Use ICE_MAX_NUM_DESC_BY_MAC() for ring limits rather than
 * ICE_MAX_RING_DESC directly, as E830 needs a lower cap.
 */
#define ICE_MAX_NUM_DESC_BY_MAC(hw) ...
```

This is a minor style preference and the current placement is acceptable.

### 2. Arithmetic correctness check

**File:** `drivers/net/intel/ice/ice_rxtx.h`  
**Line:** `#define ICE_MAX_RING_DESC    (8192 - 32)`

The define evaluates to 8160, matching the commit message's statement about the "generic maximum of 8160." The E830-specific limit is 8096. Both values are well below the overflow point mentioned in the commit message (the 13-bit queue length field, which can represent values up to 8191). The arithmetic is correct.

### 3. Correctness verification

The patch correctly replaces hardcoded `ICE_MAX_RING_DESC` with `ICE_MAX_NUM_DESC_BY_MAC(hw)` in:
- `dev_info` advertisement (`ice_dev_info_get`)
- Queue setup validation (`ice_rx_queue_setup`, `ice_tx_queue_setup`)

This ensures the advertised limits and validation checks now match the actual ring allocation, which already used the MAC-specific macro. The fix prevents the descriptor count overflow described in the commit message.

Review-Result: CLEAN


More information about the test-report mailing list