|WARNING| [2/2] examples/vhost: remove unused but set globals
dpdklab at iol.unh.edu
dpdklab at iol.unh.edu
Thu Sep 3 21:35:07 CEST 2026
Test-Label: ai-code-review
Test-Status: WARNING
https://dpdk.org/patch/169081
_AI Code Review_
=== Patch Review: series.patch (via Claude) ===
Review date: 2026-09-03
# DPDK Patch Review
## Patch 1/2: examples/qos_sched: fix unused but set global errors
### Correctness
No correctness issues found. The patch removes dead code (variables that were written but never read).
### Style and Process
**Info:**
The patch removes unused global variables `app_numa_mask` and `app_used_port_mask` which were being set but never read. This is appropriate cleanup triggered by a clang warning.
**Observation:**
The declaration `uint32_t app_numa_mask = 0;` in `init.c` is being removed, but the variable was `static` in `args.c`. These were separate variables with the same name - the global one in `init.c` appears to be leftover dead code.
## Patch 2/2: examples/vhost: remove unused but set globals
### Correctness
No correctness issues found. The patch removes dead code.
### Style and Process
**Info:**
The patch removes unused variables `num_queues` and `num_vmdq_queues` that were being set but never read. This is appropriate cleanup.
---
## Overall Assessment
Both patches are straightforward dead code removal motivated by clang warnings. No functional changes are made, and the removed code was genuinely unused.
### Summary
**Errors:** None
**Warnings:** None
**Info:**
- Patch 1: Removes two unused global variables (`app_numa_mask`, `app_used_port_mask`)
- Patch 2: Removes two unused variables (`num_queues`, `num_vmdq_queues`)
Both patches are appropriate fixes for `-Wunused-but-set-global` warnings and improve code cleanliness by removing dead code. The Fixes tags and stable at dpdk.org Cc are appropriate since these are bug fixes (even if minor).
More information about the test-report
mailing list