diff options
author | Suravee Suthikulpanit <suravee.suthikulpanit@amd.com> | 2019-11-14 14:15:14 -0600 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2020-02-05 15:17:43 +0100 |
commit | 9a0bf05430699dc94b7ced940f6270c7cf1d77ef (patch) | |
tree | 5c88a9e9a81cbf399dcc2eb6a9458aeadc5f9ce2 /arch/x86/include | |
parent | f4fdc0a2edf48f16f7b10cceaf4781fc56ab7fd9 (diff) | |
download | linux-9a0bf05430699dc94b7ced940f6270c7cf1d77ef.tar.bz2 |
svm: Deactivate AVIC when launching guest with nested SVM support
Since AVIC does not currently work w/ nested virtualization,
deactivate AVIC for the guest if setting CPUID Fn80000001_ECX[SVM]
(i.e. indicate support for SVM, which is needed for nested virtualization).
Also, introduce a new APICV_INHIBIT_REASON_NESTED bit to be used for
this reason.
Suggested-by: Alexander Graf <graf@amazon.com>
Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'arch/x86/include')
-rw-r--r-- | arch/x86/include/asm/kvm_host.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h index 90bfe8becc56..ce19dea5f2dd 100644 --- a/arch/x86/include/asm/kvm_host.h +++ b/arch/x86/include/asm/kvm_host.h @@ -877,6 +877,7 @@ enum kvm_irqchip_mode { #define APICV_INHIBIT_REASON_DISABLE 0 #define APICV_INHIBIT_REASON_HYPERV 1 +#define APICV_INHIBIT_REASON_NESTED 2 struct kvm_arch { unsigned long n_used_mmu_pages; |