mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 10:58:48 +09:00
ANDROID: KVM: arm64: Only call kvm_shadow_destroy() in protected mode
Non-protected mode doesn't have a shadow state. Bug: 220829442 Signed-off-by: Fuad Tabba <tabba@google.com> Change-Id: I38f7eb94a8fd02cc796b943cdcda4ff379b1bb64
This commit is contained in:
committed by
Quentin Perret
parent
50d8a0882d
commit
0863f25b5d
@@ -231,7 +231,9 @@ void kvm_arch_destroy_vm(struct kvm *kvm)
|
||||
bitmap_free(kvm->arch.pmu_filter);
|
||||
|
||||
kvm_vgic_destroy(kvm);
|
||||
kvm_shadow_destroy(kvm);
|
||||
|
||||
if (is_protected_kvm_enabled())
|
||||
kvm_shadow_destroy(kvm);
|
||||
|
||||
for (i = 0; i < KVM_MAX_VCPUS; ++i) {
|
||||
if (kvm->vcpus[i]) {
|
||||
|
||||
Reference in New Issue
Block a user