All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH v2 0/2] tick/nohz: Add per-CPU control of non-idle tick suppression
@ 2026-10-17 13:13 Peng Wang
  2026-10-17 13:13 ` [RFC PATCH v2 1/2] tick/nohz: Add a policy dependency for full dynticks Peng Wang
  2026-10-17 13:13 ` [RFC PATCH v2 2/2] cpu: Add per-CPU control of non-idle tick suppression Peng Wang
  0 siblings, 2 replies; 3+ messages in thread
From: Peng Wang @ 2026-10-17 13:13 UTC (permalink / raw)
  To: Anna-Maria Behnsen, Frederic Weisbecker, Ingo Molnar,
	Thomas Gleixner
  Cc: Peng Wang, Greg Kroah-Hartman, Rafael J . Wysocki,
	Danilo Krummrich, Steven Rostedt, Masami Hiramatsu,
	Mathieu Desnoyers, Peter Zijlstra, Waiman Long, Tejun Heo,
	He Rongguang, linux-kernel, linux-api, driver-core,
	linux-trace-kernel, cgroups

This series adds per-CPU control of non-idle tick suppression within
the boot-time nohz_full set. The policy can be changed without taking
CPUs offline.

Some cloud hosts pin vCPU threads one-to-one to host CPUs. At full
allocation, housekeeping CPUs also provide vCPU capacity and always
retain their non-idle tick. Operators want comparable performance for
otherwise equivalent vCPUs, regardless of CPU placement. Retaining the
non-idle tick on nohz_full CPUs as well avoids one placement-dependent
difference in host tick interference.

With spare capacity, selected nohz_full CPUs may stop the tick to reduce
host scheduler-tick interference with vCPUs. Allocation changes as VMs
are created or destroyed while other VMs remain running. A vCPU thread
may be the only runnable task in either state, so existing tick
dependencies do not express this policy.

The per-CPU nohz_tick_allowed boolean defaults to 1 (allowed). Writing
0 prevents non-idle tick suppression; writing 1 allows it, subject to
existing dependencies. Readback reports permission, not tick state.
This leaves idle tick suppression, nohz_full membership, context
tracking, RCU offloading and housekeeping configuration unchanged.

This series depends on the separately submitted nohz kick fix [2].
Testing used that fix together with this series in x86_64 KVM guests,
with NO_HZ_FULL enabled and disabled.

Changes since v1:
- Following Greg's sysfs feedback [1], replace the global CPU list with
  a per-CPU boolean, removing the list-size and custom parsing issues.
- Rename nohz_full_allowed to nohz_tick_allowed, as suggested by Waiman.
- Explain the vCPU allocation use case and clarify permission semantics.

v1: https://lore.kernel.org/all/cover.1792067271.git.peng_wang@linux.alibaba.com/
[1] https://lore.kernel.org/all/2026101743-monotype-demeaning-f97b@gregkh/
[2] "tick/nohz: Requeue kicks flushed outside hardirq context"
    Message-ID: <43668cf88d976084e2865ec07dea82b64ad402ba.1792240863.git.peng_wang@linux.alibaba.com>

Peng Wang (2):
  tick/nohz: Add a policy dependency for full dynticks
  cpu: Add per-CPU control of non-idle tick suppression

 .../ABI/testing/sysfs-devices-system-cpu      | 27 ++++++++++
 drivers/base/cpu.c                            | 53 +++++++++++++++++++
 include/linux/tick.h                          |  8 ++-
 include/trace/events/timer.h                  |  3 +-
 kernel/time/tick-sched.c                      | 42 +++++++++++++++
 5 files changed, 130 insertions(+), 3 deletions(-)


base-commit: 70dd4ee72eb2d5793c62e71c14e3aba78e5a4e56
prerequisite-patch-id: 6036ece815f0ab92a0413d433675d5b240b7a8c1
-- 
2.47.0


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

end of thread, other threads:[~2026-10-17 13:14 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-17 13:13 [RFC PATCH v2 0/2] tick/nohz: Add per-CPU control of non-idle tick suppression Peng Wang
2026-10-17 13:13 ` [RFC PATCH v2 1/2] tick/nohz: Add a policy dependency for full dynticks Peng Wang
2026-10-17 13:13 ` [RFC PATCH v2 2/2] cpu: Add per-CPU control of non-idle tick suppression Peng Wang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.