Re: [PATCH net 1/2] net/mlx5e: psp: Fix invalid access on PSP dev registration fail

Jakub Kicinski
2026-04-23T02:59:49Z

On Wed, 22 Apr 2026 15:13:04 +0000 Cosmin Ratiu wrote:
> > > Can you call mlx5e_psp_cleanup() when register fails for now?
> >
> > Done for the next version, currently undergoing testing.
>
> There's a snag: priv->psp may be accessed concurrently from
> mlx5e_get_stats() -> mlx5e_fold_sw_stats64() so we'd need to play
> tricks with RCU and that goes beyond what a net fix should be: It's a
> redesign of how priv->psp is handled in the driver. There's a risk we
> are missing things, or it becomes more intrusive that what a fix should
> be.

Questionable.

> I would like to ask you: let's please not do this redesign of priv->psp
> in a rush, and leave it for the net-next series I mentioned...
>
> To reiterate, would you like to take patch 2?

Sure, whatever. But it has to be reposted, of course.