public inbox for [email protected]
 help / color / mirror / Atom feed
* [PATCH 6.1 0/2] io_uring/io-wq: respect cgroup cpusets
@ 2024-09-11 16:23 Felix Moessbauer
  2024-09-11 16:23 ` [PATCH 6.1 1/2] io_uring/io-wq: do not allow pinning outside of cpuset Felix Moessbauer
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Felix Moessbauer @ 2024-09-11 16:23 UTC (permalink / raw)
  To: axboe
  Cc: stable, asml.silence, linux-kernel, io-uring, cgroups, dqminh,
	longman, adriaan.schmidt, florian.bezdeka, Felix Moessbauer

Hi,

as discussed in [1], this is a manual backport of the remaining two
patches to let the io worker threads respect the affinites defined by
the cgroup of the process.

In 6.1 one worker is created per NUMA node, while in da64d6db3bd3
("io_uring: One wqe per wq") this is changed to only have a single worker.
As this patch is pretty invasive, Jens and me agreed to not backport it.

Instead we now limit the workers cpuset to the cpus that are in the
intersection between what the cgroup allows and what the NUMA node has.
This leaves the question what to do in case the intersection is empty:
To be backwarts compatible, we allow this case, but restrict the cpumask
of the poller to the cpuset defined by the cgroup. We further believe
this is a reasonable decision, as da64d6db3bd3 drops the NUMA awareness
anyways.

[1] https://lore.kernel.org/lkml/[email protected]

Best regards,
Felix Moessbauer
Siemens AG

Felix Moessbauer (2):
  io_uring/io-wq: do not allow pinning outside of cpuset
  io_uring/io-wq: inherit cpuset of cgroup in io worker

 io_uring/io-wq.c | 33 ++++++++++++++++++++++++++-------
 1 file changed, 26 insertions(+), 7 deletions(-)

-- 
2.39.2


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-09-11 16:28 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-11 16:23 [PATCH 6.1 0/2] io_uring/io-wq: respect cgroup cpusets Felix Moessbauer
2024-09-11 16:23 ` [PATCH 6.1 1/2] io_uring/io-wq: do not allow pinning outside of cpuset Felix Moessbauer
2024-09-11 16:23 ` [PATCH 6.1 2/2] io_uring/io-wq: inherit cpuset of cgroup in io worker Felix Moessbauer
2024-09-11 16:28 ` [PATCH 6.1 0/2] io_uring/io-wq: respect cgroup cpusets Jens Axboe

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox