From: patchwork-bot+netdevbpf@kernel.org
To: Duoming Zhou <duoming@zju.edu.cn>
Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
pabeni@redhat.com, kuba@kernel.org, edumazet@google.com,
davem@davemloft.net, andrew+netdev@lunn.ch,
UNGLinuxDriver@microchip.com, alexandre.belloni@bootlin.com,
claudiu.manoil@nxp.com, vladimir.oltean@nxp.com
Subject: Re: [PATCH v2 net] net: mscc: ocelot: Fix use-after-free caused by cyclic delayed work
Date: Mon, 06 Oct 2025 18:30:16 +0000 [thread overview]
Message-ID: <175977541624.1511446.1704376269622300510.git-patchwork-notify@kernel.org> (raw)
In-Reply-To: <20251001011149.55073-1-duoming@zju.edu.cn>
Hello:
This patch was applied to netdev/net.git (main)
by Jakub Kicinski <kuba@kernel.org>:
On Wed, 1 Oct 2025 09:11:49 +0800 you wrote:
> The origin code calls cancel_delayed_work() in ocelot_stats_deinit()
> to cancel the cyclic delayed work item ocelot->stats_work. However,
> cancel_delayed_work() may fail to cancel the work item if it is already
> executing. While destroy_workqueue() does wait for all pending work items
> in the work queue to complete before destroying the work queue, it cannot
> prevent the delayed work item from being rescheduled within the
> ocelot_check_stats_work() function. This limitation exists because the
> delayed work item is only enqueued into the work queue after its timer
> expires. Before the timer expiration, destroy_workqueue() has no visibility
> of this pending work item. Once the work queue appears empty,
> destroy_workqueue() proceeds with destruction. When the timer eventually
> expires, the delayed work item gets queued again, leading to the following
> warning:
>
> [...]
Here is the summary with links:
- [v2,net] net: mscc: ocelot: Fix use-after-free caused by cyclic delayed work
https://git.kernel.org/netdev/net/c/bc9ea7870796
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
prev parent reply other threads:[~2025-10-06 18:30 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-01 1:11 Duoming Zhou
2025-10-06 18:30 ` patchwork-bot+netdevbpf [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=175977541624.1511446.1704376269622300510.git-patchwork-notify@kernel.org \
--to=patchwork-bot+netdevbpf@kernel.org \
--cc=UNGLinuxDriver@microchip.com \
--cc=alexandre.belloni@bootlin.com \
--cc=andrew+netdev@lunn.ch \
--cc=claudiu.manoil@nxp.com \
--cc=davem@davemloft.net \
--cc=duoming@zju.edu.cn \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=vladimir.oltean@nxp.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®