All of lore.kernel.org
 help / color / mirror / Atom feed
From: Oleg Nesterov <oleg@redhat.com>
To: luca.boccassi@gmail.com
Cc: linux-kernel@vger.kernel.org, christian@brauner.io
Subject: Re: [PATCH v6] pidfd: add ioctl to retrieve pid info
Date: Mon, 7 Oct 2024 07:51:34 +0200	[thread overview]
Message-ID: <20241007055133.GA1333@redhat.com> (raw)
In-Reply-To: <20241006213530.335087-1-luca.boccassi@gmail.com>

On 10/06, luca.boccassi@gmail.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.


  reply	other threads:[~2024-10-07  5:51 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-06 21:33 [PATCH v6] pidfd: add ioctl to retrieve pid info luca.boccassi
2024-10-07  5:51 ` Oleg Nesterov [this message]
2024-10-07  9:45   ` Luca Boccassi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20241007055133.GA1333@redhat.com \
    --to=oleg@redhat.com \
    --cc=christian@brauner.io \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luca.boccassi@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.