All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hao Luo <haoluo@google.com>
To: Tejun Heo <tj@kernel.org>
Cc: "Yosry Ahmed" <yosryahmed@google.com>,
	"Michal Koutný" <mkoutny@suse.com>,
	"Linux Kernel Mailing List" <linux-kernel@vger.kernel.org>,
	Cgroups <cgroups@vger.kernel.org>, bpf <bpf@vger.kernel.org>,
	"Aditya Kali" <adityakali@google.com>,
	"Serge Hallyn" <serge.hallyn@canonical.com>,
	"Roman Gushchin" <roman.gushchin@linux.dev>,
	"Yonghong Song" <yhs@fb.com>,
	"Muneendra Kumar" <muneendra.kumar@broadcom.com>
Subject: Re: [PATCH 4/4] cgroup/bpf: Honor cgroup NS in cgroup_iter for ancestors
Date: Mon, 29 Aug 2022 11:02:36 -0700	[thread overview]
Message-ID: <CA+khW7jZCN54nUonNLp59fTAqOtAk_Ror+PgrLBfufRcE-CnFQ@mail.gmail.com> (raw)
In-Reply-To: <Ywz8J70t3508J62n@slm.duckdns.org>

On Mon, Aug 29, 2022 at 10:49 AM Tejun Heo <tj@kernel.org> wrote:
>
> On Mon, Aug 29, 2022 at 10:30:45AM -0700, Yosry Ahmed wrote:
> > > I'd like to clarify, if a process A in a broad cgroup ns sets up a BPF
> > > cgroup iterator, exposes it via bpffs and than a process B in a narrowed
> > > cgroup ns (which excludes the origin cgroup) wants to traverse the
> > > iterator, should it fail straight ahead (regardless of iter order)?
> > > The alternative would be to allow self-dereference but prohibit any
> > > iterator moves (regardless of order).
> > >
> >
> > imo it should fail straight ahead, but maybe others (Tejun? Hao?) have
> > other opinions here.
>
> Yeah, I'd prefer it to fail right away as that's simple and gives us the
> most choices for the future.
>

Thanks Michal for fixing the cgroup iter use case! I agree that
failing straight ahead is better. I don't envision a use case that
wants the alternative.

> Thanks.
>
> --
> tejun

  reply	other threads:[~2022-08-29 18:02 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-26 16:52 [PATCH 0/4] Honor cgroup namespace when resolving cgroup id Michal Koutný
2022-08-26 16:52 ` Michal Koutný
2022-08-26 16:52 ` [PATCH 1/4] cgroup: Honor caller's cgroup NS when resolving path Michal Koutný
2022-08-26 16:52   ` Michal Koutný
2022-08-26 16:52 ` [PATCH 2/4] cgroup: cgroup: Honor caller's cgroup NS when resolving cgroup id Michal Koutný
2022-08-26 16:52   ` Michal Koutný
2022-08-26 16:52 ` [PATCH 3/4] cgroup: Homogenize cgroup_get_from_id() return value Michal Koutný
2022-08-26 16:52   ` Michal Koutný
2022-08-26 16:52 ` [PATCH 4/4] cgroup/bpf: Honor cgroup NS in cgroup_iter for ancestors Michal Koutný
2022-08-26 16:52   ` Michal Koutný
2022-08-26 17:41   ` Yosry Ahmed
2022-08-29 12:59     ` Michal Koutný
2022-08-29 12:59       ` Michal Koutný
2022-08-29 17:30       ` Yosry Ahmed
2022-08-29 17:30         ` Yosry Ahmed
2022-08-29 17:49         ` Tejun Heo
2022-08-29 18:02           ` Hao Luo [this message]
2022-08-26 20:59 ` [PATCH 0/4] Honor cgroup namespace when resolving cgroup id Tejun Heo
2022-08-26 21:08 ` Tejun Heo

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=CA+khW7jZCN54nUonNLp59fTAqOtAk_Ror+PgrLBfufRcE-CnFQ@mail.gmail.com \
    --to=haoluo@google.com \
    --cc=adityakali@google.com \
    --cc=bpf@vger.kernel.org \
    --cc=cgroups@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mkoutny@suse.com \
    --cc=muneendra.kumar@broadcom.com \
    --cc=roman.gushchin@linux.dev \
    --cc=serge.hallyn@canonical.com \
    --cc=tj@kernel.org \
    --cc=yhs@fb.com \
    --cc=yosryahmed@google.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.