|
|
Log in / Subscribe / Register

sched/nohz: Make kcpustat's CPUTIME_SYSTEM vtime aware v2 (Partially fix kcpustat on nohz_full)

From:  Frederic Weisbecker <frederic-AT-kernel.org>
To:  LKML <linux-kernel-AT-vger.kernel.org>
Subject:  [PATCH 00/14] sched/nohz: Make kcpustat's CPUTIME_SYSTEM vtime aware v2 (Partially fix kcpustat on nohz_full)
Date:  Wed, 16 Oct 2019 04:56:46 +0200
Message-ID:  <20191016025700.31277-1-frederic@kernel.org>
Cc:  Frederic Weisbecker <frederic-AT-kernel.org>, Jacek Anaszewski <jacek.anaszewski-AT-gmail.com>, Peter Zijlstra <peterz-AT-infradead.org>, Wanpeng Li <wanpengli-AT-tencent.com>, "Rafael J . Wysocki" <rjw-AT-rjwysocki.net>, Rik van Riel <riel-AT-surriel.com>, Thomas Gleixner <tglx-AT-linutronix.de>, Yauheni Kaliuta <yauheni.kaliuta-AT-redhat.com>, Ingo Molnar <mingo-AT-kernel.org>, Viresh Kumar <viresh.kumar-AT-linaro.org>, Pavel Machek <pavel-AT-ucw.cz>
Archive-link:  Article

Thanks to the recent patches that have brought a sensible rq->curr RCU
lifecycle, here comes a simplified rework of
	"[PATCH 00/25] sched/nohz: Make kcpustat vtime aware"

See for the record and a summary: https://lore.kernel.org/lkml/1542163569-20047-1-git-send-...

Since I'm trying to cut and simplify the series, this one only fixes
the reading of kcpustat's system field for now. But that also provides
all the necessary preparation work for the rest.

User and guest time will have their own series because niceness brings
issues of its own.

git://git.kernel.org/pub/scm/linux/kernel/git/frederic/linux-dynticks.git
	nohz/kcpustat-v2

HEAD: e179e89320c53a96c5d585af38126cfb124da789

Thanks,
	Frederic
---

Frederic Weisbecker (14):
      sched/vtime: Record CPU under seqcount for kcpustat needs
      sched/cputime: Add vtime idle task state
      sched/cputime: Add vtime guest task state
      context_tracking: Remove context_tracking_active()
      context_tracking: s/context_tracking_is_enabled/context_tracking_enabled()
      context_tracking: Rename context_tracking_is_cpu_enabled() to context_tracking_enabled_this_cpu()
      context_tracking: Introduce context_tracking_enabled_cpu()
      sched/vtime: Rename vtime_accounting_cpu_enabled() to vtime_accounting_enabled_this_cpu()
      sched/vtime: Introduce vtime_accounting_enabled_cpu()
      context_tracking: Check static key on context_tracking_enabled_*cpu()
      sched/kcpustat: Introduce vtime-aware kcpustat accessor for CPUTIME_SYSTEM
      procfs: Use vtime aware kcpustat accessor to fetch CPUTIME_SYSTEM
      cpufreq: Use vtime aware kcpustat accessor to fetch CPUTIME_SYSTEM
      leds: Use vtime aware kcpustat accessor to fetch CPUTIME_SYSTEM


 arch/x86/entry/calling.h                |   2 +-
 drivers/cpufreq/cpufreq.c               |   2 +-
 drivers/leds/trigger/ledtrig-activity.c |   2 +-
 fs/proc/stat.c                          |   4 +-
 include/linux/context_tracking.h        |  26 +++----
 include/linux/context_tracking_state.h  |  21 +++---
 include/linux/kernel_stat.h             |  11 +++
 include/linux/sched.h                   |   9 ++-
 include/linux/tick.h                    |   2 +-
 include/linux/vtime.h                   |  23 +++---
 kernel/context_tracking.c               |   6 +-
 kernel/sched/cputime.c                  | 119 ++++++++++++++++++++++++++++----
 kernel/time/tick-sched.c                |   2 +-
 13 files changed, 172 insertions(+), 57 deletions(-)


Copyright © 2019, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds