diff --git a/xen/arch/x86/mm/p2m-pt.c b/xen/arch/x86/mm/p2m-pt.c index 5c64008208..cf6d2a4c6a 100644 --- a/xen/arch/x86/mm/p2m-pt.c +++ b/xen/arch/x86/mm/p2m-pt.c @@ -483,7 +483,7 @@ int p2m_pt_handle_deferred_changes(uint64_t gpa) /* Reconstruct a fake p2m_access_t from stored PTE flags. */ static p2m_access_t p2m_flags_to_access(unsigned int flags) { - if ( flags & _PAGE_PRESENT ) + if ( !(flags & _PAGE_PRESENT) ) return p2m_access_n; /* No need to look at _PAGE_NX for now. */