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]
Date:   Fri, 6 Jan 2023 13:19:34 -0800
From:   Jakub Kicinski <kuba@...nel.org>
To:     Jacob Keller <jacob.e.keller@...el.com>
Cc:     <davem@...emloft.net>, <netdev@...r.kernel.org>,
        <edumazet@...gle.com>, <pabeni@...hat.com>, <jiri@...nulli.us>
Subject: Re: [PATCH net-next 4/9] devlink: always check if the devlink
 instance is registered

On Fri, 6 Jan 2023 09:03:18 -0800 Jacob Keller wrote:
> > +static inline bool devl_is_registered(struct devlink *devlink)
> > +{
> > +	/* To prevent races the caller must hold the instance lock
> > +	 * or another lock taken during unregistration.
> > +	 */  
> 
> Why not just lockdep_assert here on the instance lock? I guess this
> comment implies that another lock could be used instead but it seems
> weird to allow that? I guess because of things like the linecards_lock
> as opposed to the instance lock?

Yup, as discussed on the RFC - removing the regions lock specifically 
is quite tricky.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ