Actions
Bug #9499
open
LS
LS
dpdk: compile error with DPDK 26.11
Bug #9499:
dpdk: compile error with DPDK 26.11
Affected Versions:
Effort:
Difficulty:
Label:
Description
Suricata does not compile against DPDK 26.11, the new LTS release:
util-dpdk.c: In function 'DPDKGetPortNameByPortID': util-dpdk.c:123:19: error: too few arguments to function 'rte_eth_dev_get_name_by_port'; expected 3, have 2 rte_ethdev.h:5569:1: note: declared here 5569 | rte_eth_dev_get_name_by_port(uint16_t port_id, char *name, size_t size);
DPDK 26.11 added a size parameter to rte_eth_dev_get_name_by_port() (26.11 release notes, API changes: "ethdev: Added size parameter to rte_eth_dev_get_name_by_port()"). DPDK 26.07 and older keep the two-argument form.
This is the only compile error with 26.11. The same call is present in main and main-8.0.x (src/util-dpdk.c).
Steps to reproduce¶
- Build and install DPDK 26.11
./configure --enable-dpdkmake
Proposed solution¶
Pass the size of the name buffer on DPDK 26.11 and newer, behind an RTE_VERSION check, and keep the two-argument call for older versions.
Actions