mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
p2m-pt: avoid hard-coding Xen's PAT
This makes the code much easier to understand. No functional change intended. As per Andrew Cooper, the existing logic is questionable, but this does not make it any worse. Signed-off-by: Demi Marie Obenour <demi@invisiblethingslab.com> Acked-by: Jan Beulich <jbeulich@suse.com>
This commit is contained in:
1 parent
88168c418c
commit
1ca8af08df
1 file changed
+3
-3
@@ -99,13 +99,13 @@ static unsigned long p2m_type_to_flags(const struct p2m_domain *p2m,
|
||||
return flags | P2M_BASE_FLAGS | _PAGE_RW | _PAGE_NX_BIT;
|
||||
case p2m_mmio_direct:
|
||||
if ( !rangeset_contains_singleton(mmio_ro_ranges, mfn_x(mfn)) )
|
||||
flags |= _PAGE_RW;
|
||||
flags |= _PAGE_RW | _PAGE_UCM;
|
||||
else
|
||||
{
|
||||
flags |= _PAGE_PWT;
|
||||
flags |= _PAGE_UC;
|
||||
ASSERT(!level);
|
||||
}
|
||||
return flags | P2M_BASE_FLAGS | _PAGE_PCD;
|
||||
return flags | P2M_BASE_FLAGS;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||