linux-doc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH v3 0/9] pids controller events rework and migration charging
@ 2024-04-05 17:05 Michal Koutný
  2024-04-05 17:05 ` [RFC PATCH v3 1/9] cgroup/pids: Remove superfluous zeroing Michal Koutný
                   ` (8 more replies)
  0 siblings, 9 replies; 21+ messages in thread
From: Michal Koutný @ 2024-04-05 17:05 UTC (permalink / raw)
  To: cgroups, linux-doc, linux-kernel, linux-kselftest
  Cc: Tejun Heo, Zefan Li, Johannes Weiner, Jonathan Corbet, Shuah Khan

The series consists of two parts:
- pids.events rework (originally v2, patches 1-6,
- migration charging, patches 7-9.

The changes are independent in principle, I stacked them for (my)
convenience and because they both deserve RFC:

1) Changed semantics of v2 pids.events
  - similar change was proposed for memory.swap.events:max [1]
2) Migration charging is obsolete concept

How are the new events supposed to be useful?

- pids.events.local:max
  - tells that cgroup's limit is hit (too tight?)
- pids.events.local:max.imposed
  - tells that cgroup's workload was restricted (generalization of
    'cgroup: fork rejected by pids controller in %s' message)
- pids.events:*
  - "only" directs top-down search to cgroups of interest

The migration charging is motivated by apparenty surprising
	pids.current > pids.max
because supervised processes are forked in supervisor's cgroup (more
details in commit cgroup/pids: Enforce pids.max on task migrations too)

Changes from v2 (https://lore.kernel.org/r/20200205134426.10570-1-mkoutny@suse.com)
- implemented pids.events.local (Tejun)
- added migration charging

[1] https://lore.kernel.org/r/20230202155626.1829121-1-hannes@cmpxchg.org/

Michal Koutný (9):
  cgroup/pids: Remove superfluous zeroing
  cgroup/pids: Separate semantics of pids.events related to pids.max
  cgroup/pids: Make event counters hierarchical
  cgroup/pids: Add pids.events.local
  selftests: cgroup: Lexicographic order in Makefile
  selftests: cgroup: Add basic tests for pids controller
  cgroup/pids: Replace uncharge/charge pair with a single function
  cgroup/pids: Enforce pids.max on task migrations
  selftests: cgroup: Add tests pids controller

 Documentation/admin-guide/cgroup-v1/pids.rst |   3 +-
 Documentation/admin-guide/cgroup-v2.rst      |  22 +-
 include/linux/cgroup-defs.h                  |   7 +-
 kernel/cgroup/cgroup.c                       |  16 +-
 kernel/cgroup/pids.c                         | 206 +++++++++----
 tools/testing/selftests/cgroup/Makefile      |  25 +-
 tools/testing/selftests/cgroup/test_pids.c   | 302 +++++++++++++++++++
 7 files changed, 514 insertions(+), 67 deletions(-)
 create mode 100644 tools/testing/selftests/cgroup/test_pids.c


base-commit: 026e680b0a08a62b1d948e5a8ca78700bfac0e6e
-- 
2.44.0


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

end of thread, other threads:[~2024-04-12 17:04 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-05 17:05 [RFC PATCH v3 0/9] pids controller events rework and migration charging Michal Koutný
2024-04-05 17:05 ` [RFC PATCH v3 1/9] cgroup/pids: Remove superfluous zeroing Michal Koutný
2024-04-05 17:05 ` [RFC PATCH v3 2/9] cgroup/pids: Separate semantics of pids.events related to pids.max Michal Koutný
2024-04-08 17:55   ` Tejun Heo
2024-04-09 16:02     ` Johannes Weiner
2024-04-12 14:23     ` Michal Koutný
2024-04-12 17:04       ` Tejun Heo
2024-04-05 17:05 ` [RFC PATCH v3 3/9] cgroup/pids: Make event counters hierarchical Michal Koutný
2024-04-05 17:05 ` [RFC PATCH v3 4/9] cgroup/pids: Add pids.events.local Michal Koutný
2024-04-05 17:05 ` [RFC PATCH v3 5/9] selftests: cgroup: Lexicographic order in Makefile Michal Koutný
2024-04-05 17:05 ` [RFC PATCH v3 6/9] selftests: cgroup: Add basic tests for pids controller Michal Koutný
2024-04-06 21:37   ` Muhammad Usama Anjum
2024-04-08 11:29     ` Michal Koutný
2024-04-08 11:53       ` Muhammad Usama Anjum
2024-04-08 12:01         ` Michal Koutný
2024-04-08 12:04           ` Muhammad Usama Anjum
2024-04-09  0:12             ` Waiman Long
2024-04-09 13:00               ` Muhammad Usama Anjum
2024-04-05 17:05 ` [RFC PATCH v3 7/9] cgroup/pids: Replace uncharge/charge pair with a single function Michal Koutný
2024-04-05 17:05 ` [RFC PATCH v3 8/9] cgroup/pids: Enforce pids.max on task migrations Michal Koutný
2024-04-05 17:05 ` [RFC PATCH v3 9/9] selftests: cgroup: Add tests pids controller Michal Koutný

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).