public inbox for linux-doc@vger.kernel.org
 help / color / mirror / Atom feed
From: Shashank Balaji <shashank.mahadasyam@sony.com>
To: Juri Lelli <juri.lelli@redhat.com>
Cc: Jonathan Corbet <corbet@lwn.net>,
	Peter Zijlstra <peterz@infradead.org>,
	linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org,
	Shinya Takumi <shinya.takumi@sony.com>
Subject: Re: [PATCH] sched_deadline, docs: add affinity setting with cgroup2 cpuset controller
Date: Tue, 27 May 2025 22:26:46 +0900	[thread overview]
Message-ID: <aDW9lgkZaP9pI5Jk@JPC00244420> (raw)
In-Reply-To: <aDW6EckuCFTZfPZ8@jlelli-thinkpadt14gen4.remote.csb>

Hi Juri,

On Tue, May 27, 2025 at 03:11:45PM +0200, Juri Lelli wrote:
> Hello!
> 
> On 22/05/25 17:06, Shashank Balaji wrote:
> > Setting the cpu affinity mask of a SCHED_DEADLINE process using the cgroup v1
> > cpuset controller is already detailed. Add similar information for cgroup v2's
> > cpuset controller.
> 
> Thanks a lot for working on this. Really appreaciated.

Thank you :)

> > +5.2 Using cgroup v2 cpuset controller
> > +-------------------------------------
> > +
> > + Assuming the cgroup v2 root is mounted at ``/sys/fs/cgroup``.
> > +
> > +   cd /sys/fs/cgroup
> > +   echo '+cpuset' > cgroup.subtree_control
> > +   mkdir deadline_group
> > +   echo 0 > deadline_group/cpuset.cpus
> > +   echo 'root' > deadline_group/cpuset.cpus.partition
> > +   echo $$ > deadline_group/cgroup.procs
> > +   rt-app -t 100000:10000:d:0 -D5
> 
> Sadly, the example with cgroup v1 was made at a time when rt-app still
> supported command line parameters like the above. I believe nowadays
> that is not the case anymore and one needs to create a json file
> describing the task to run it with rt-app.
> 
> I would say we should update both examples to use something a little
> more generic, e.g.,
> 
> # chrt --deadline --sched-runtime 10000000 --sched-period 100000000 0 yes >/dev/null &
> 
> What do you think?
> 
> Best,
> Juri

Haha, I was just about to send the patch with the chrt example, when I
checked out the rt-app repo and saw that it's much more powerful. I
thought, "they must have had a good reason for using rt-app instead of
chrt for the example", and switched it to rt-app at the last second. I
didn't know that rt-app doesn't support command line parameters anymore.
I'll send out v2 with the chrt example.

Thanks!

Regards,
Shashank

      reply	other threads:[~2025-05-27 13:26 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-22  8:06 [PATCH] sched_deadline, docs: add affinity setting with cgroup2 cpuset controller Shashank Balaji
2025-05-27 13:11 ` Juri Lelli
2025-05-27 13:26   ` Shashank Balaji [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=aDW9lgkZaP9pI5Jk@JPC00244420 \
    --to=shashank.mahadasyam@sony.com \
    --cc=corbet@lwn.net \
    --cc=juri.lelli@redhat.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=peterz@infradead.org \
    --cc=shinya.takumi@sony.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox