In DPDK, 'rte_socket_id' means the running socket while
'rte_eth_dev_socket_id' is the device socket.
For better performance, memory which queue setup used and device
should be in the same socket.
This patch make sure it calls rte_eth_dev_socket_id API to get device
socket_id when setting ringparam.
Signed-off-by: Chengwen Feng <fengchengwen@huawei.com>
Signed-off-by: Min Hu (Connor) <humin29@huawei.com>
return stat;
stat = rte_eth_tx_queue_setup(port_id, 0, ring_param->tx_pending,
- rte_socket_id(), NULL);
+ rte_eth_dev_socket_id(port_id), NULL);
if (stat != 0)
return stat;
stat = rte_eth_rx_queue_setup(port_id, 0, ring_param->rx_pending,
- rte_socket_id(), NULL, rx_qinfo.mp);
+ rte_eth_dev_socket_id(port_id), NULL, rx_qinfo.mp);
if (stat != 0)
return stat;