Subject: Re: [PATCH net-next 2/6] net: provide pending ring configuration in net_device

From: Jakub Kicinski <[email-masked]>
Date: Fri, 17 Jan 2025 14:18:33 -0800

On Fri, 17 Jan 2025 14:07:03 -0800 Michael Chan wrote:
> > +out_tie_cfg:
> > +       dev->cfg_pending = dev->cfg;  
> 
> If I understand this correctly, cfg_pending can momentarily point to
> the old cfg and freed memory before pointing to the new cfg outside of
> rtnl_lock.  Shouldn't it be inside the rtnl_lock?
> 
> In the bnxt patch, we now look at cfg_pending so it must always point
> to the correct cfg.

Good catch, I moved it out to avoid an allocation under rtnl_lock..
-- 
pw-bot: cr