Re: [PATCH net-next v3 RESEND] net: phy: nxp-tja11xx: cancel registration work on remove
Andrew Lunn <[email protected]>
| Newsgroups | org.kernel.vger.netdev,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <[email protected]> |
On Wed, Jul 29, 2026 at 11:53:22PM +0800, Hongyan Xu wrote: > tja1102_p0_probe() schedules work to register the second port. That work > uses the Port 0 private data and phydev. The private data is > devm-allocated, but the driver does not wait for the pending work on > remove. > > Store the Port 0 private data in phydev->priv and add a remove callback. > The callback cancels the registration work before devres teardown frees > the state. > > This issue was found by a static analysis tool. > > Reviewed-by: Andrew Lunn <[email protected]> > Signed-off-by: Hongyan Xu <[email protected]> Reviewed-by: Andrew Lunn <[email protected]> Andrew