Subject: Re: [PATCH net] nfp: flower: avoid taking mutex in atomic context

From: Leon Romanovsky <[email-masked]>
Date: Wed, 1 Feb 2023 10:21:51 +0200

On Tue, Jan 31, 2023 at 01:21:29PM -0800, Jakub Kicinski wrote:
> On Tue, 31 Jan 2023 15:27:51 +0200 Leon Romanovsky wrote:
> > > > > +	if ((port_id & NFP_FL_LAG_OUT) == NFP_FL_LAG_OUT) {
> > > > > +		memset(&lag_info, 0, sizeof(struct nfp_tun_neigh_lag));  
> > > > 
> > > > This memset can be removed if you initialize lag_info to zero.
> > > > struct nfp_tun_neigh_lag lag_info = {};  
> > > 
> > > Happy to change if that is preferred.
> > > Is it preferred?  
> > 
> > I don't see why it can't be preferred.
> 
> It's too subjective to make Simon respin, IMO.

I'm not insisting on respin, but would like to hear why writing compact
code with cleared variable on stack, which anyway needs to be cleared is
not preferred.

Thanks