[PATCH v1 5/7] event/dlb2: avoid credit release race condition
    Pravin Pathak 
    pravin.pathak at intel.com
       
    Fri May  9 06:23:59 CEST 2025
    
    
  
While unlinking ports, all associated credits should be released.
This commit avoids race condition when main thread is unlinking
while workers are running.
Signed-off-by: Pravin Pathak <pravin.pathak at intel.com>
---
 drivers/event/dlb2/dlb2.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/event/dlb2/dlb2.c b/drivers/event/dlb2/dlb2.c
index cd843bb9d0..5f3b816665 100644
--- a/drivers/event/dlb2/dlb2.c
+++ b/drivers/event/dlb2/dlb2.c
@@ -2664,7 +2664,7 @@ dlb2_eventdev_port_unlink(struct rte_eventdev *dev, void *event_port,
 		DLB2_LOG_LINE_DBG("dlb2: ignore unlink from dir port %d",
 			     ev_port->id);
 		rte_errno = 0;
-		return nb_unlinks; /* as if success */
+		goto ret_credits;
 	}
 
 	dlb2 = ev_port->dlb2;
-- 
2.25.1
    
    
More information about the dev
mailing list