[PATCH v4 3/4] timer: fix function to stop all timers

Carrillo, Erik G erik.g.carrillo at intel.com
Thu Aug 18 15:12:52 CEST 2022


> -----Original Message-----
> From: Naga Harish K, S V <s.v.naga.harish.k at intel.com>
> Sent: Friday, August 12, 2022 11:08 AM
> To: Carrillo, Erik G <erik.g.carrillo at intel.com>
> Cc: dev at dpdk.org; stable at dpdk.org
> Subject: [PATCH v4 3/4] timer: fix function to stop all timers
> 
> There is a possibility of deadlock in this API, as same spinlock is tried to be
> acquired in nested manner.
> 
> If the lcore that is stopping the timer is different from the lcore that owns the
> timer, the timer list lock is acquired in timer_del(), even if local_is_locked is
> true. Because the same lock was already acquired in rte_timer_stop_all(),
> the thread will hang.
> 
> This patch removes the acquisition of nested lock.
> 
> Fixes: 821c51267bcd63a ("timer: add function to stop all timers in a list")
> Cc: stable at dpdk.org
> 
> Signed-off-by: Naga Harish K S V <s.v.naga.harish.k at intel.com>
Acked-by: Erik Gabriel Carrillo <erik.g.carrillo at intel.com>


More information about the stable mailing list