[PATCH] net/mlx5: fix the unlock mismatch issue

Slava Ovsiienko viacheslavo at nvidia.com
Tue Nov 7 07:52:37 CET 2023


Hi, Weiguo

Good catch, thank you.

With best regards,
Slava

> -----Original Message-----
> From: Weiguo Li <liwg06 at foxmail.com>
> Sent: Saturday, November 4, 2023 6:08 AM
> To: Alexander Kozyrev <akozyrev at nvidia.com>
> Cc: Slava Ovsiienko <viacheslavo at nvidia.com>; dev at dpdk.org;
> stable at dpdk.org; Weiguo Li <liweiguo at xencore.cn>
> Subject: [PATCH] net/mlx5: fix the unlock mismatch issue
> 
> The 'need_lock' parameter controls whether the function acquires and
> releases the spinlock, but the first unlock operation occurs regardless of the
> 'need_lock' parameter.
> 
> To fix this issue, the spin unlock operation should be invoked within an 'if
> (need_lock)' block, ensuring that the function only unlocks the spinlock if it
> has previously been acquired.
> 
> Fixes: 48fbb0e93d06 ("net/mlx5: support flow meter mark indirect action
> with HWS")
> Cc: stable at dpdk.org
> 
> Signed-off-by: Weiguo Li <liweiguo at xencore.cn>
Acked-by: Viacheslav Ovsiienko <viacheslavo at nvidia.com>



More information about the stable mailing list