]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: SVM: Remove unnecessary APICv/AVIC update in vCPU unblocking path
authorSean Christopherson <seanjc@google.com>
Wed, 8 Dec 2021 01:52:22 +0000 (01:52 +0000)
committerPaolo Bonzini <pbonzini@redhat.com>
Wed, 19 Jan 2022 17:14:42 +0000 (12:14 -0500)
commit0d830730880acf3f7597cd8a0b78797d1a36c1df
tree94332cd0822bc83324edcad215ed045f068b963a
parentb5f86368557a8ed983e4862852156a7fc34bd570
KVM: SVM: Remove unnecessary APICv/AVIC update in vCPU unblocking path

Remove handling of KVM_REQ_APICV_UPDATE from svm_vcpu_unblocking(), it's
no longer needed as it was made obsolete by commit b0941c5a85f3 ("KVM:
SVM: call avic_vcpu_load/avic_vcpu_put when enabling/disabling AVIC").
Prior to that commit, the manual check was necessary to ensure the AVIC
stuff was updated by avic_set_running() when a request to enable APICv
became pending while the vCPU was blocking, as the request handling
itself would not do the update.  But, as evidenced by the commit, that
logic was flawed and subject to various races.

Now that svm_refresh_apicv_exec_ctrl() does avic_vcpu_load/put() in
response to an APICv status change, drop the manual check in the
unblocking path.

Suggested-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Sean Christopherson <seanjc@google.com>
Message-Id: <20211208015236.1616697-13-seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/svm/avic.c