[Bug,805] af_xdp PMD is broken with primary/secondary process
Checks
Context |
Check |
Description |
ci/Intel-compilation |
warning
|
apply issues
|
Commit Message
https://bugs.dpdk.org/show_bug.cgi?id=805
Bug ID: 805
Summary: af_xdp PMD is broken with primary/secondary process
Product: DPDK
Version: 21.11
Hardware: All
OS: Linux
Status: UNCONFIRMED
Severity: major
Priority: Normal
Component: core
Assignee: dev@dpdk.org
Reporter: stephen@networkplumber.org
Target Milestone: ---
AF_XDP PMD is broken for primary/secondary process model.
Both the procinfo, pdump and other applications need to be able to basic
calls from secondary process.
There is one bug easy bug, where af_xdp crashes when calling
rte_eth_info_get() in secondary process because eth_dev->device
was not set.
But there is a bigger problem when code calls rte_eth_stats_get().
The af_xdp PMD tries to send a request to kernel to get the number
of missed packets; but the file descriptor is only valid in the primary
process. Fixing this is much deeper and requires opening a different
socket in each process, and will XDP in kernel handle this correctly?
I think we should just mark AF_XDP as broken in with primary/secondary
and return an error in probe in secondary process.
Comments
https://bugs.dpdk.org/show_bug.cgi?id=805
Ciara Loftus (ciara.loftus@intel.com) changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |ciara.loftus@intel.com
Resolution|--- |FIXED
Status|UNCONFIRMED |RESOLVED
--- Comment #1 from Ciara Loftus (ciara.loftus@intel.com) ---
Fix pushed to net-next tree:
http://git.dpdk.org/next/dpdk-next-net/commit/?id=2fcc36c234b558013f163313c81cdcb13878933d
@@ -1800,6 +1800,7 @@ rte_pmd_af_xdp_probe(struct rte_vdev_device *dev)
return -EINVAL;
}
eth_dev->dev_ops = &ops;
+ eth_dev->device = &dev->device;
rte_eth_dev_probing_finish(eth_dev);
return 0;
}