Re: [PATCH 1/7] cgroup: Implement cgroup_show_cftypes()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello, Michal.

On Tue, Aug 20, 2024 at 04:38:40PM +0200, Michal Koutný wrote:
> On Wed, Aug 07, 2024 at 02:25:23PM GMT, Tejun Heo <tj@xxxxxxxxxx> wrote:
> > +void cgroup_show_cftype(struct cftype *cft, bool show)
> > +{
> > +	struct cgroup_subsys *ss = cft->ss;
> > +	struct cgroup *root = ss ? &ss->root->cgrp : &cgrp_dfl_root.cgrp;
> 
> Strictly speaking, this (v1) cgroup_root dereference should be guarded
> with cgroup_mutex too (should be the root destroy concurrently).

Ah, right. I think I might just drop this patch. Hiding and showing the
interface files dynamically doesn't seem to work that well in practive (ie.
it causes more production problems than it solves). Something a bit more
boring like triggering a warning when a unimplemented feature is used is
probably better here.

Thanks.

-- 
tejun




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]     [Monitors]

  Powered by Linux