From e846cfdec34cc58b9a1a2438d313028246b8e986 Mon Sep 17 00:00:00 2001 From: Nikhil Rao Date: Wed, 21 Nov 2018 03:39:15 +0530 Subject: [PATCH] eventdev: fix unlock in Rx adapter In the eth Rx adapter SW service function, move the return to after the spinlock unlock. Coverity issue: 302857 Fixes: a66a83744667 ("eventdev: fix Rx SW adapter stop") Cc: stable@dpdk.org Signed-off-by: Nikhil Rao Acked-by: Jerin Jacob --- lib/librte_eventdev/rte_event_eth_rx_adapter.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/librte_eventdev/rte_event_eth_rx_adapter.c b/lib/librte_eventdev/rte_event_eth_rx_adapter.c index 71d008cd19..8831bc35f9 100644 --- a/lib/librte_eventdev/rte_event_eth_rx_adapter.c +++ b/lib/librte_eventdev/rte_event_eth_rx_adapter.c @@ -1165,8 +1165,8 @@ rxa_service_func(void *args) if (rte_spinlock_trylock(&rx_adapter->rx_lock) == 0) return 0; if (!rx_adapter->rxa_started) { - return 0; rte_spinlock_unlock(&rx_adapter->rx_lock); + return 0; } stats = &rx_adapter->stats; -- 2.20.1