]> Pileus Git - ~andy/linux/blobdiff - arch/x86/kvm/paging_tmpl.h
Merge tag 'virtio-next-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
[~andy/linux] / arch / x86 / kvm / paging_tmpl.h
index fb50fa64f36cc93a39a9452e6c349eb3878d71bf..7769699d48a80caac0e1d8402280ab1e15b99bed 100644 (file)
@@ -552,9 +552,12 @@ static int FNAME(page_fault)(struct kvm_vcpu *vcpu, gva_t addr, u32 error_code,
 
        pgprintk("%s: addr %lx err %x\n", __func__, addr, error_code);
 
-       if (unlikely(error_code & PFERR_RSVD_MASK))
-               return handle_mmio_page_fault(vcpu, addr, error_code,
+       if (unlikely(error_code & PFERR_RSVD_MASK)) {
+               r = handle_mmio_page_fault(vcpu, addr, error_code,
                                              mmu_is_nested(vcpu));
+               if (likely(r != RET_MMIO_PF_INVALID))
+                       return r;
+       };
 
        r = mmu_topup_memory_caches(vcpu);
        if (r)