diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c index 266bdaf0ce44d13bd80a895c44001d290ef37213..0ed662dc72d27e3d70409381e87271608e71b0f6 100644 --- a/virt/kvm/kvm_main.c +++ b/virt/kvm/kvm_main.c @@ -535,8 +535,10 @@ static inline int valid_vcpu(int n) inline int kvm_is_mmio_pfn(pfn_t pfn) { - if (pfn_valid(pfn)) - return PageReserved(pfn_to_page(pfn)); + if (pfn_valid(pfn)) { + struct page *page = compound_head(pfn_to_page(pfn)); + return PageReserved(page); + } return true; }