Commit 9271817
committed
dpdk/eal: fix secondary process calling eal_bus_cleanup() (#860)
Secondary processes (e.g. ff_ifconfig, ff_sysctl) should not invoke
eal_bus_cleanup() on exit, because it calls drv->remove() on every PCI
device. For the virtio PMD this eventually reaches virtio_reset(), which
writes VIRTIO_CONFIG_STATUS_RESET (0x00) to the device status register
and resets the NIC hardware. The primary process (F-Stack / nginx) loses
its NIC after that and stops accepting new connections.
Root cause: commit 1cab1a40ea9b ("bus: cleanup devices on shutdown",
DPDK 22.11) added eal_bus_cleanup() to rte_eal_cleanup() without
distinguishing primary from secondary processes.
Fix: guard eal_bus_cleanup() with a primary-process check, identical to
the approach in upstream DPDK commit 4bc53f8f0d64 ("eal: fix MP socket
cleanup", merged for DPDK 25.07). Backported here for the bundled
DPDK 23.11.5.
Fixes: #8601 parent c105f32 commit 9271817
1 file changed
Lines changed: 12 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1370 | 1370 | | |
1371 | 1371 | | |
1372 | 1372 | | |
1373 | | - | |
| 1373 | + | |
| 1374 | + | |
| 1375 | + | |
| 1376 | + | |
| 1377 | + | |
| 1378 | + | |
| 1379 | + | |
| 1380 | + | |
| 1381 | + | |
| 1382 | + | |
| 1383 | + | |
| 1384 | + | |
1374 | 1385 | | |
1375 | 1386 | | |
1376 | 1387 | | |
| |||
0 commit comments