diff options
Diffstat (limited to 'arch/x86/kvm/mmu.c')
-rw-r--r-- | arch/x86/kvm/mmu.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c index 28c8fbcc6763..01ca00423938 100644 --- a/arch/x86/kvm/mmu.c +++ b/arch/x86/kvm/mmu.c | |||
@@ -4090,6 +4090,9 @@ static void kvm_mmu_remove_some_alloc_mmu_pages(struct kvm *kvm, | |||
4090 | { | 4090 | { |
4091 | struct kvm_mmu_page *page; | 4091 | struct kvm_mmu_page *page; |
4092 | 4092 | ||
4093 | if (list_empty(&kvm->arch.active_mmu_pages)) | ||
4094 | return; | ||
4095 | |||
4093 | page = container_of(kvm->arch.active_mmu_pages.prev, | 4096 | page = container_of(kvm->arch.active_mmu_pages.prev, |
4094 | struct kvm_mmu_page, link); | 4097 | struct kvm_mmu_page, link); |
4095 | kvm_mmu_prepare_zap_page(kvm, page, invalid_list); | 4098 | kvm_mmu_prepare_zap_page(kvm, page, invalid_list); |