eventdev/eth_tx: fix adapter stop

adapter_stop function is stopping the adapter service using
rte_service_runstate_set() API and waiting until
rte_service_may_be_active() API returns stopped state in an
infinite loop.

This results in hang issues if application calls
rte_service_lcore_stop() before adapter stop.

Remove the state check after setting the service state which
avoids running into hang issues. This also makes Tx adapter stop
inline with remaining adapters.

Fixes: a3bbf2e097 ("eventdev: add eth Tx adapter implementation")
Cc: stable@dpdk.org

Signed-off-by: Naga Harish K S V <s.v.naga.harish.k@intel.com>
Acked-by: Jay Jayatheerthan <jay.jayatheerthan@intel.com>
This commit is contained in:
Naga Harish K S V 2022-07-25 23:22:11 -05:00 committed by Jerin Jacob
parent 2ab9869c01
commit fbb9f7e215

View File

@ -509,10 +509,6 @@ txa_service_ctrl(uint8_t id, int start)
ret = rte_service_runstate_set(txa->service_id, start);
rte_spinlock_unlock(&txa->tx_lock);
if (ret == 0 && !start) {
while (rte_service_may_be_active(txa->service_id))
rte_pause();
}
return ret;
}