]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: x86: Skip KVM_GUESTDBG_BLOCKIRQ APICv update if APICv is disabled
authorSean Christopherson <seanjc@google.com>
Wed, 20 Apr 2022 01:37:32 +0000 (01:37 +0000)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 21 Apr 2022 17:16:13 +0000 (13:16 -0400)
commitd9d6c6a5e699344d3c5b01f0bd60cc97f0b1e749
tree097a1b1aecbfd58dd5a411ae5592766897a131c0
parent892858425e8305c4ddfc88ef183c091b33ef7191
KVM: x86: Skip KVM_GUESTDBG_BLOCKIRQ APICv update if APICv is disabled

Skip the APICv inhibit update for KVM_GUESTDBG_BLOCKIRQ if APICv is
disabled at the module level to avoid having to acquire the mutex and
potentially process all vCPUs. The DISABLE inhibit will (barring bugs)
never be lifted, so piling on more inhibits is unnecessary.

Fixes: 4fe180dc1b9a ("KVM: x86: inhibit APICv when KVM_GUESTDBG_BLOCKIRQ active")
Cc: Maxim Levitsky <mlevitsk@redhat.com>
Signed-off-by: Sean Christopherson <seanjc@google.com>
Reviewed-by: Maxim Levitsky <mlevitsk@redhat.com>
Message-Id: <20220420013732.3308816-5-seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/x86.c