sched/vtime: Move guest enter/exit vtime accounting to vtime.h
authorSean Christopherson <seanjc@google.com>
Wed, 5 May 2021 00:27:32 +0000 (17:27 -0700)
committerThomas Gleixner <tglx@linutronix.de>
Wed, 5 May 2021 20:54:11 +0000 (22:54 +0200)
commit6f922b89e5518143920b10e3643e556d9df58d94
tree0a6afd2d14aeabc85a2302cf6b3acb9467eaca4b
parentb41c723b203e19480c26f2ec8f04eedc03d34b34
sched/vtime: Move guest enter/exit vtime accounting to vtime.h

Provide separate helpers for guest enter vtime accounting (in addition to
the existing guest exit helpers), and move all vtime accounting helpers
to vtime.h where the existing #ifdef infrastructure can be leveraged to
better delineate the different types of accounting.  This will also allow
future cleanups via deduplication of context tracking code.

Opportunstically delete the vtime_account_kernel() stub now that all
callers are wrapped with CONFIG_VIRT_CPU_ACCOUNTING_NATIVE=y.

No functional change intended.

Signed-off-by: Sean Christopherson <seanjc@google.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lore.kernel.org/r/20210505002735.1684165-6-seanjc@google.com
include/linux/context_tracking.h
include/linux/vtime.h