Caught by code inspection, for a non-EAL thread identified with
rte_lcore_id() == LCORE_ID_ANY, the code currently arbitrarily uses
lcore 0 while there is no guarantee this lcore is used.
Fixes:
3588aaa68eab ("net/mrvl: fix HIF objects allocation")
Cc: stable@dpdk.org
Signed-off-by: David Marchand <david.marchand@redhat.com>
Acked-by: Liron Himi <lironh@marvell.com>
unsigned int core_id = rte_lcore_id();
if (core_id == LCORE_ID_ANY)
- core_id = 0;
+ core_id = rte_get_master_lcore();
hif = mrvl_get_hif(priv, core_id);
core_id = rte_lcore_id();
if (core_id == LCORE_ID_ANY)
- core_id = 0;
+ core_id = rte_get_master_lcore();
hif = mrvl_get_hif(rxq->priv, core_id);
if (!hif)
unsigned int core_id = rte_lcore_id();
if (core_id == LCORE_ID_ANY)
- core_id = 0;
+ core_id = rte_get_master_lcore();
if (!q)
return;