lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250418142958.6ews5uuoqayc7lof@skbuf>
Date: Fri, 18 Apr 2025 17:29:58 +0300
From: Vladimir Oltean <olteanv@...il.com>
To: Wei Fang <wei.fang@....com>
Cc: Jakub Kicinski <kuba@...nel.org>,
	Claudiu Manoil <claudiu.manoil@....com>,
	Vladimir Oltean <vladimir.oltean@....com>,
	Clark Wang <xiaoning.wang@....com>,
	"andrew+netdev@...n.ch" <andrew+netdev@...n.ch>,
	"davem@...emloft.net" <davem@...emloft.net>,
	"edumazet@...gle.com" <edumazet@...gle.com>,
	"pabeni@...hat.com" <pabeni@...hat.com>,
	"christophe.leroy@...roup.eu" <christophe.leroy@...roup.eu>,
	"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"imx@...ts.linux.dev" <imx@...ts.linux.dev>,
	"linuxppc-dev@...ts.ozlabs.org" <linuxppc-dev@...ts.ozlabs.org>,
	"linux-arm-kernel@...ts.infradead.org" <linux-arm-kernel@...ts.infradead.org>
Subject: Re: [PATCH v5 net-next 04/14] net: enetc: add MAC filtering for
 i.MX95 ENETC PF

On Wed, Apr 16, 2025 at 05:16:15AM +0000, Wei Fang wrote:
> > -----Original Message-----
> > From: Jakub Kicinski <kuba@...nel.org>
> > Sent: 2025年4月16日 11:43
> > To: Wei Fang <wei.fang@....com>
> > Cc: Claudiu Manoil <claudiu.manoil@....com>; Vladimir Oltean
> > <vladimir.oltean@....com>; Clark Wang <xiaoning.wang@....com>;
> > andrew+netdev@...n.ch; davem@...emloft.net; edumazet@...gle.com;
> > pabeni@...hat.com; christophe.leroy@...roup.eu; netdev@...r.kernel.org;
> > linux-kernel@...r.kernel.org; imx@...ts.linux.dev; linuxppc-dev@...ts.ozlabs.org;
> > linux-arm-kernel@...ts.infradead.org
> > Subject: Re: [PATCH v5 net-next 04/14] net: enetc: add MAC filtering for i.MX95
> > ENETC PF
> > 
> > On Fri, 11 Apr 2025 17:57:42 +0800 Wei Fang wrote:
> > >  	enetc4_pf_netdev_destroy(si);
> > >  	enetc4_pf_free(pf);
> > > +	destroy_workqueue(si->workqueue);
> > 
> > I think that you need to flush or cancel the work after unregistering
> > the netdev but before freeing it? The work may access netdev after its
> > freed.
> 
> Yes, you are right, I will improve it. thanks.

I think the workqueue creation needs to be handled in
enetc4_pf_netdev_create() somewhere in between alloc_etherdev_mqs() and
register_netdev(), so that the workqueue is available as soon as the
interface is registered, but also so that the workqueue teardown takes
places naturally where Jakub indicated.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ