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: <20241113074331.B48iqBgp@linutronix.de>
Date: Wed, 13 Nov 2024 08:43:31 +0100
From: Sebastian Andrzej Siewior <bigeasy@...utronix.de>
To: Tejun Heo <tj@...nel.org>
Cc: cgroups@...r.kernel.org, linux-kernel@...r.kernel.org,
	Michal Koutný <mkoutny@...e.com>,
	"Paul E. McKenney" <paulmck@...nel.org>,
	Boqun Feng <boqun.feng@...il.com>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Hillf Danton <hdanton@...a.com>,
	Johannes Weiner <hannes@...xchg.org>,
	Marco Elver <elver@...gle.com>, Zefan Li <lizefan.x@...edance.com>,
	tglx@...utronix.de,
	syzbot+6ea37e2e6ffccf41a7e6@...kaller.appspotmail.com
Subject: Re: [PATCH v2 2/2] cgroup, kernfs: Move cgroup to the RCU interface
 for name lookups

On 2024-11-12 08:59:16 [-1000], Tejun Heo wrote:
> Hello,

Hi,

> On Tue, Nov 12, 2024 at 04:52:39PM +0100, Sebastian Andrzej Siewior wrote:
> ...
> >  /**
> > - * pr_cont_kernfs_name - pr_cont name of a kernfs_node
> > + * pr_cont_kernfs_name_rcu - pr_cont name of a kernfs_node
> >   * @kn: kernfs_node of interest
> >   *
> > - * This function can be called from any context.
> > + * This function can be called from any context. The root node must be with
> > + * KERNFS_ROOT_SAME_PARENT.
> >   */
> > -void pr_cont_kernfs_name(struct kernfs_node *kn)
> > +void pr_cont_kernfs_name_rcu(struct kernfs_node *kn)
> 
> Having to split the interface all the way up isn't great. While there are
> also downsides, I wonder whether a better approach here is just making the
> backend function (kernfs_path_from_node()) automatically use RCU locking if
> the flag is set rather than propagating the difference by splitting the
> interface. The distinction doesn't mean anything to most users after all.

Indeed.

> Thanks.
> 

Sebastian

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ