Re: [PATCH net] net: mana: Fix race on per-CQ variable napi work_done
From: patchwork-bot+netdevbpf
Date: Tue Dec 06 2022 - 05:30:23 EST
Hello:
This patch was applied to netdev/net.git (master)
by Paolo Abeni <pabeni@xxxxxxxxxx>:
On Fri, 2 Dec 2022 11:43:10 -0800 you wrote:
> After calling napi_complete_done(), the NAPIF_STATE_SCHED bit may be
> cleared, and another CPU can start napi thread and access per-CQ variable,
> cq->work_done. If the other thread (for example, from busy_poll) sets
> it to a value >= budget, this thread will continue to run when it should
> stop, and cause memory corruption and panic.
>
> To fix this issue, save the per-CQ work_done variable in a local variable
> before napi_complete_done(), so it won't be corrupted by a possible
> concurrent thread after napi_complete_done().
>
> [...]
Here is the summary with links:
- [net] net: mana: Fix race on per-CQ variable napi work_done
https://git.kernel.org/netdev/net/c/18010ff776fa
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html