|SUCCESS| net/iavf: fix interrupt callback race on close

dpdklab at iol.unh.edu dpdklab at iol.unh.edu
Wed Oct 14 15:33:09 CEST 2026


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

_AI Code Review_

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

# DPDK Patch Review

## ERRORS

None.

## WARNINGS

None.

## INFO

**Correctness improvement in interrupt handling synchronization**

The patch correctly addresses a race condition between `iavf_dev_close()` and the interrupt thread. The original code's use of `rte_intr_callback_unregister()` allows the unregister to return `-EAGAIN` when a callback is running, leaving the callback registered. This creates two concrete failure modes that the commit message documents with precision:

1. The interrupt thread can resume after `dev->data` is set to NULL, causing a segfault in `iavf_handle_virtchnl_msg()`
2. The eventfd is closed while the source remains registered, triggering an epoll_ctl panic at `rte_eal_cleanup()`

The fix -- switching to `rte_intr_callback_unregister_sync()` -- is appropriate here because `iavf_dev_interrupt_handler()` itself never closes or reinitializes the port (it delegates to the iavf-event thread), so the sync call will not deadlock.

The same fix is applied to the `iavf_dev_init()` error path, which has the identical pattern.

**Pattern matches ice driver**

The commit message notes that `ice_dev_close()` already uses the sync variant, which is correct -- this brings iavf into alignment with ice.

Review-Result: CLEAN


More information about the test-report mailing list