]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: x86: Add wrappers for setting/clearing APICv inhibits
authorSean Christopherson <seanjc@google.com>
Fri, 11 Mar 2022 04:35:16 +0000 (04:35 +0000)
committerPaolo Bonzini <pbonzini@redhat.com>
Sat, 2 Apr 2022 09:34:44 +0000 (05:34 -0400)
commit2e034ed291910119561f2b8094692474049449ea
tree3eded2731ddb4340de106cfbe5807a8438dc26de
parentfdb3fa08d654fa329ec5a944085c31e2f6528452
KVM: x86: Add wrappers for setting/clearing APICv inhibits

Add set/clear wrappers for toggling APICv inhibits to make the call sites
more readable, and opportunistically rename the inner helpers to align
with the new wrappers and to make them more readable as well.  Invert the
flag from "activate" to "set"; activate is painfully ambiguous as it's
not obvious if the inhibit is being activated, or if APICv is being
activated, in which case the inhibit is being deactivated.

For the functions that take @set, swap the order of the inhibit reason
and @set so that the call sites are visually similar to those that bounce
through the wrapper.

Signed-off-by: Sean Christopherson <seanjc@google.com>
Message-Id: <20220311043517.17027-3-seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/include/asm/kvm_host.h
arch/x86/kvm/hyperv.c
arch/x86/kvm/i8254.c
arch/x86/kvm/svm/svm.c
arch/x86/kvm/trace.h
arch/x86/kvm/x86.c