Re: [PATCH 0/1] software node: Use-after-free fix in drivers/base/swnode.c
From: Mike Isely
Date: Wed Feb 25 2026 - 14:00:40 EST
On Wed, 25 Feb 2026, Andy Shevchenko wrote:
> On Tue, Feb 24, 2026 at 01:19:21PM -0600, mike.isely@xxxxxxxxxxxxxxxxx wrote:
>
> > Correct issue in drivers/base/swnode.c that can lead to use-after-free
> > due to kobject reference counting error, which itself is due to
> > incorrect behavior with the "managed" struct swnode flag in
> > circumstances involving child struct device instances where the parent
> > struct device is managing a struct swnode.
> >
> > Use-after-free in this case led to an Oops and a subsequent kernel
> > memory leak, but realistically it's kernel heap corruption, so any
> > manner of chaos can result, if left unaddressed.
> >
> > This was detected in kernel 6.12, verified also in kernel 6.6. Visual
> > inspection in 6.19.3 source (the latest as of right now) shows the
>
> The latest is v7.0-rc1 as of time of the topic message.
I actually meant the latest release. Guess I should have checked the
latest release candidate on the off-chance that it might have been
addressed.
>
> > same issue. The nearly trivial fix was verified in 6.12. While this
> > patches against 6.19.3, IMHO this is a candidate for all LTS kernels.
>
> Thanks for the contribution, usually for a single patch there is no need
> in cover letter. The comment block can handle this (the place after cutter
> '---' line in the message with a patch).
Yeah, a separate cover letter is overkill, but I was just following a
process here.
-Mike
isely@xxxxxxxxx