linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH RFC 00/12] Implementation of Dynamic Housekeeping & Enhanced Isolation (DHEI)
@ 2026-02-06  7:04 Qiliang Yuan
  2026-02-06  7:04 ` [PATCH RFC 01/12] sched/isolation: Remove __init restriction from housekeeping cores Qiliang Yuan
                   ` (12 more replies)
  0 siblings, 13 replies; 16+ messages in thread
From: Qiliang Yuan @ 2026-02-06  7:04 UTC (permalink / raw)
  To: Ingo Molnar, Peter Zijlstra, Juri Lelli, Vincent Guittot,
	Dietmar Eggemann, Steven Rostedt, Ben Segall, Mel Gorman,
	Valentin Schneider, Thomas Gleixner, Paul E. McKenney,
	Frederic Weisbecker, Neeraj Upadhyay, Joel Fernandes,
	Josh Triplett, Boqun Feng, Uladzislau Rezki, Mathieu Desnoyers,
	Lai Jiangshan, Zqiang, Tejun Heo, Andrew Morton, Vlastimil Babka,
	Suren Baghdasaryan, Michal Hocko, Brendan Jackman,
	Johannes Weiner, Zi Yan, Anna-Maria Behnsen, Ingo Molnar
  Cc: linux-kernel, rcu, linux-mm, Qiliang Yuan, Qiliang Yuan

The Linux kernel provides mechanisms like 'isolcpus' and 'nohz_full' to
reduce interference for latency-sensitive workloads. However, these are
locked behind the "Reboot Wall" - they can only be configured via boot
parameters and require a system restart to change.

*** THIS IS AN RFC ***
This series is being submitted as an Request For Comments to discuss the
architectural changes required to support dynamic reconfiguration of
housekeeping boundaries. Key points for discussion:
- The use of a blocking notifier chain for cross-subsystem synchronization.
- Compatibility with existing boot-time isolcpus and nohz_full parameters.
- User-space sysfs interface design for granular isolation control.

While cgroup2 (cpuset) provides task-centric resource partitioning (including
unbound kthreads), it lacks the infrastructure to reconfigure core kernel
subsystems or manage per-CPU kernel activities. Specifically, cgroups cannot:
- Managed interrupt (IRQ) migration.
- RCU callback offloading and grace-period kthread placement.
- Per-CPU kernel threads (e.g., watchdog/n) and global subsystem logic (e.g., kcompactd).
- Subsystem-level masks for unbound workqueues.
- Dynamic toggling of full dynticks (NOHZ_FULL) mode.

This patch series introduces Dynamic Housekeeping & Enhanced Isolation
(DHEI). DHEI allows administrators to reconfigure the kernel's
housekeeping boundaries at runtime via a new sysfs interface at
/sys/kernel/housekeeping/.

Core Architecture:
1. Notifier-Driven Synchronization: A new blocking notifier chain
   (HK_UPDATE_MASK) allows isolation.c to signal all participating
   subsystems (IRQ, RCU, Sched, Watchdog, Workqueue, kcompactd, Tick)
   whenever a housekeeping mask is modified.
2. Decoupled Memory Management: Replaced boot-time memory allocators
   with runtime-safe variants, allowing masks to be allocated or resized
   after the system is running.
3. Subsystem Handlers: Each critical subsystem implements a reconfiguration
   handler to migrate pending work, re-affine kthreads, or re-route
   interrupts dynamically.

Key Features:
- Fine-grained control: Separate sysfs nodes for timer, rcu, tick,
  workqueue, kthread, etc.
- Dynamic NOHZ_FULL: Supports enabling/disabling full dynticks mode
  on-the-fly by re-kicking CPUs to evaluate tick dependencies.
- SMT Awareness: An optional 'smt_aware_mode' ensures that all SMT
  siblings of a physical core stay in the same isolation state.
- Safety Guard: Prevents the isolation of all CPUs, ensuring at least
  one online CPU is always available for housekeeping tasks.

This series provides the necessary infrastructure for cloud-native
orchestrators and high-frequency trading platforms to dynamically
re-partition CPU resources without incurring the downtime of a reboot.

Signed-off-by: Qiliang Yuan <realwujing@gmail.com>
---
Qiliang Yuan (12):
      sched/isolation: Remove __init restriction from housekeeping cores
      sched/isolation: Introduce reconfiguration notifier chain
      genirq: Implement dynamic migration for Managed IRQs
      rcu: Sync RCU housekeeping mask on notification
      sched/core: Dynamic update housekeeping_cpumask(HK_TYPE_DOMAIN)
      watchdog: Allow runtime toggle of hardlockup detector on CPUs
      workqueue: Dynamic housekeeping mask update support
      kcompactd: Add housekeeping notifier for dynamic mask update
      sched/isolation: Separate housekeeping types and add sysfs interface
      tick/nohz: Implement dynamic nohz_full state update
      sched/isolation: Implement SMT sibling auto-isolation and safety check
      sched/isolation: Bridge isolcpus and support runtime tick offload init

 include/linux/sched/isolation.h |  40 +++++--
 include/linux/tick.h            |   2 +-
 kernel/irq/manage.c             |  52 +++++++++
 kernel/rcu/tree.c               |  43 +++++++
 kernel/sched/core.c             |   5 +-
 kernel/sched/isolation.c        | 252 ++++++++++++++++++++++++++++++++++++++--
 kernel/sched/sched.h            |   2 +-
 kernel/sched/topology.c         |  26 +++++
 kernel/time/tick-sched.c        |  63 +++++++++-
 kernel/watchdog.c               |  24 ++++
 kernel/workqueue.c              |  39 +++++++
 mm/compaction.c                 |  26 +++++
 12 files changed, 547 insertions(+), 27 deletions(-)
---
base-commit: 1f97d9dcf53649c41c33227b345a36902cbb08ad
change-id: 20260206-feature-dynamic_isolcpus_dhei-ee46b6e3a477

Best regards,
-- 
Qiliang Yuan <realwujing@gmail.com>



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

end of thread, other threads:[~2026-02-20 19:07 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-02-06  7:04 [PATCH RFC 00/12] Implementation of Dynamic Housekeeping & Enhanced Isolation (DHEI) Qiliang Yuan
2026-02-06  7:04 ` [PATCH RFC 01/12] sched/isolation: Remove __init restriction from housekeeping cores Qiliang Yuan
2026-02-06  7:04 ` [PATCH RFC 02/12] sched/isolation: Introduce reconfiguration notifier chain Qiliang Yuan
2026-02-06  7:04 ` [PATCH RFC 03/12] genirq: Implement dynamic migration for Managed IRQs Qiliang Yuan
2026-02-06 12:24   ` Thomas Gleixner
2026-02-06  7:04 ` [PATCH RFC 04/12] rcu: Sync RCU housekeeping mask on notification Qiliang Yuan
2026-02-06  7:04 ` [PATCH RFC 05/12] sched/core: Dynamic update housekeeping_cpumask(HK_TYPE_DOMAIN) Qiliang Yuan
2026-02-06  7:04 ` [PATCH RFC 06/12] watchdog: Allow runtime toggle of hardlockup detector on CPUs Qiliang Yuan
2026-02-06  7:04 ` [PATCH RFC 07/12] workqueue: Dynamic housekeeping mask update support Qiliang Yuan
2026-02-06  7:04 ` [PATCH RFC 08/12] kcompactd: Add housekeeping notifier for dynamic mask update Qiliang Yuan
2026-02-06 15:09   ` Zi Yan
2026-02-06  7:04 ` [PATCH RFC 09/12] sched/isolation: Separate housekeeping types and add sysfs interface Qiliang Yuan
2026-02-06  7:04 ` [PATCH RFC 10/12] tick/nohz: Implement dynamic nohz_full state update Qiliang Yuan
2026-02-06  7:04 ` [PATCH RFC 11/12] sched/isolation: Implement SMT sibling auto-isolation and safety check Qiliang Yuan
2026-02-06  7:04 ` [PATCH RFC 12/12] sched/isolation: Bridge isolcpus and support runtime tick offload init Qiliang Yuan
2026-02-20 19:07 ` [PATCH RFC 00/12] Implementation of Dynamic Housekeeping & Enhanced Isolation (DHEI) Joel Fernandes

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