[PATCH net] net: airoha: Fix schedule while atomic in airoha_ppe_deinit()
Lorenzo Bianconi
lorenzo at kernel.org
Mon Jan 5 00:33:03 PST 2026
> On Tue, 23 Dec 2025 22:56:44 +0100 Lorenzo Bianconi wrote:
> > Rely on rcu_replace_pointer in airoha_ppe_deinit routine in order to fix
> > schedule while atomic issue.
>
> The information in the commit message is not sufficient.
> What "schedule while atomic issue"?
The issue is we run kzalloc() with GFP_KERNEL in airoha_npu_ppe_deinit()
in atomic context but we do not really need atomic context there.
I will fix the commit log in v2.
Regards,
Lorenzo
>
> > - npu = rcu_dereference(eth->npu);
> > + mutex_lock(&flow_offload_mutex);
> > +
> > + npu = rcu_replace_pointer(eth->npu, NULL,
> > + lockdep_is_held(&flow_offload_mutex));
> > if (npu) {
> > npu->ops.ppe_deinit(npu);
> > airoha_npu_put(npu);
> --
> pw-bot: cr
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 228 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-mediatek/attachments/20260105/07e1f79b/attachment.sig>
More information about the Linux-mediatek
mailing list