[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAMw=ZnRbGbtA+HtGNv0GCfZveHGbwENK9A9MNvqzGg=5aRmR9A@mail.gmail.com>
Date: Mon, 7 Oct 2024 10:45:05 +0100
From: Luca Boccassi <luca.boccassi@...il.com>
To: Oleg Nesterov <oleg@...hat.com>
Cc: linux-kernel@...r.kernel.org, christian@...uner.io
Subject: Re: [PATCH v6] pidfd: add ioctl to retrieve pid info
On Mon, 7 Oct 2024 at 06:51, Oleg Nesterov <oleg@...hat.com> wrote:
>
> On 10/06, luca.boccassi@...il.com wrote:
> >
> > +#ifdef CONFIG_CGROUPS
> > + if (request_mask & PIDFD_INFO_CGROUPID) {
> > + rcu_read_lock();
> > + struct cgroup *cgrp = task_cgroup(task, pids_cgrp_id);
> > + if (!cgrp)
> > + return -ENODEV;
>
> return without rcu_read_unlock().
>
> And iirc this is against the coding style, "struct cgroup *cgrp" should
> be declared at the start of block.
>
> Oleg.
Whops, thanks, fixed in v7
Powered by blists - more mailing lists