public inbox for cgroups@vger.kernel.org
 help / color / mirror / Atom feed
From: Petr Malat <oss@malat.biz>
To: Waiman Long <longman@redhat.com>
Cc: cgroups@vger.kernel.org, tj@kernel.org
Subject: Re: [RFC/POC]: Make cpuset.cpus.effective independent of cpuset.cpus
Date: Fri, 22 Mar 2024 06:54:08 +0100	[thread overview]
Message-ID: <Zf0dAAJ1BH469Oea@ntb.petris.klfree.czf> (raw)
In-Reply-To: <7b932090-5513-478e-90ff-62832d8acefb@redhat.com>

Hi,
On Thu, Mar 21, 2024 at 09:41:43PM -0400, Waiman Long wrote:
> On 3/21/24 17:33, Petr Malat wrote:
> > Hi!
> > I have tried to use the new remote cgroup feature and I find the
> > interface unfriendly - requiring cpuset.cpus.exclusive to be a subset
> > of cpuset.cpus requires the program, which wants to isolate a CPU for
> > some RT activity, to know what CPUs all ancestor cgroups want to use.
> > 
> > For example consider cgroup hierarchy c1/c2/c3 where my program is
> > running and wants to isolate CPU N, so
> >   - It creates new c1/c2/c3/rt cgroup
> >   - It adds N to cpuset.cpus.exclusive of rt, c3 and c2 cgroup
> >     (cpuset.cpus.exclusive |= N)
> >   - Now it should do the same with cpuset.cpus, but that's not possible
> >     if ancestors cpuset.cpus is empty, which is common configuration and
> >     there is no good way how to set it in that case.
> > 
> > My proposal is to
> >   - Not require cpuset.cpus.exclusive to be a subset of cpuset.cpus
> >   - Create remote cgroup if cpuset.cpus is empty and local cgroup if it's
> >     set, to give the user explicit control on what cgroup is created.
> 
> I think we can make cpuset.cpus.exclusive independent of cpuset.cpus as a
> separate hierarchy to make creation of remote partitions easier. I need some
> more time to think through it. I don't think your test patch is enough for
> making this change. BTW, you confuse cpuset.cpus.exclusive with
> cpuset.cpus.effective which are two completely different things.

The exclusive/effective confusion is a copy and paste mistake in the
description, the code should make cpuset.cpus.exclusive independent on
cpuset.cpus, how is described in the initial mail. I have pasted it
from my clipboard history and apparently haven't read the whole string.
  P.

      reply	other threads:[~2024-03-22  5:54 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-21 21:33 [RFC/POC]: Make cpuset.cpus.effective independent of cpuset.cpus Petr Malat
2024-03-21 21:39 ` [PATCH] cgroup/cpuset: " Petr Malat
2024-03-25 20:12   ` Tejun Heo
2024-03-26 15:14     ` Waiman Long
2024-03-26 16:17       ` Tejun Heo
2024-04-02 17:04   ` Michal Koutný
2024-04-04  4:36     ` Petr Malat
2024-04-04  8:09       ` Michal Koutný
2024-03-22  1:41 ` [RFC/POC]: " Waiman Long
2024-03-22  5:54   ` Petr Malat [this message]

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=Zf0dAAJ1BH469Oea@ntb.petris.klfree.czf \
    --to=oss@malat.biz \
    --cc=cgroups@vger.kernel.org \
    --cc=longman@redhat.com \
    --cc=tj@kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox