mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Tejun Heo <tj@kernel.org>
To: "lujialin (A)" <lujialin4@huawei.com>
Cc: peterz@infradead.org, Zefan Li <lizefan.x@bytedance.com>,
	cgroups@vger.kernel.org, LKML <linux-kernel@vger.kernel.org>
Subject: Re: [question] Is it possible for userspace program to control cpu usage time of RT process through cgroup2 now?
Date: Mon, 26 Sep 2022 09:12:08 -1000	[thread overview]
Message-ID: <YzH5iM0hy58f0tjd@slm.duckdns.org> (raw)
In-Reply-To: <0a83dcd5-b7fd-811c-b8d2-062115fa8c94@huawei.com>

Hello,

On Sat, Sep 24, 2022 at 05:26:20PM +0800, lujialin (A) wrote:
> Cgroup2 dose not support controling real-time processes and the cpu
> controller can only be enabled when all RT processes are in the root cgroup.
> 
> RT stuff was being overhauled when cpu controller interface for cgroup
> unified hierarchy was being implemented in 2017. It was decided that we
> would like to wait till the RT side settles down and proceed with an
> interface that better matches RT.
> 
> Is it possible for userspace program to control cpu usage time of RT process
> through cgroup2 now? If not, how is the current state looking and is there
> any proposed solution?

Not right now. The hard allocation model is pretty challenging to work with
on cgroup1 - they get enabled when cpu controller gets enabled and being
hard allocations, not allocating any prevents the cgroups from using RT at
all while allocating by default takes away from what others can use whether
that allocation is used or not, so some distros turned them off last I
checked. Overall, I'm not sure hard allocations done this way is all that
useful to manage hierarchically given that the resource has to be hard
partitioned anyway.

Can you describe your usecase?

Thanks.

-- 
tejun

      reply	other threads:[~2022-09-26 19:12 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-24  9:26 lujialin (A)
2022-09-26 19:12 ` Tejun Heo [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=YzH5iM0hy58f0tjd@slm.duckdns.org \
    --to=tj@kernel.org \
    --cc=cgroups@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lizefan.x@bytedance.com \
    --cc=lujialin4@huawei.com \
    --cc=peterz@infradead.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

all inboxes | Powered by JetHome®