|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH] x86/mm: make {set, clear}_identity_p2m_mapping() work for PV guests
Namely Dom0 suffers from commit 5ae03990c1 ("xen/vtd: create RMRR
mapping") having removed the creation of such mappings for non-
translated guests.
Reported-by: Malcolm Crossley <malcolm.crossley@xxxxxxxxxx>
Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
--- a/xen/arch/x86/mm/p2m.c
+++ b/xen/arch/x86/mm/p2m.c
@@ -957,7 +957,11 @@ int set_identity_p2m_entry(struct domain
int ret;
if ( !paging_mode_translate(p2m->domain) )
- return 0;
+ {
+ if ( !need_iommu(d) )
+ return 0;
+ return iommu_map_page(d, gfn, gfn, IOMMUF_readable|IOMMUF_writable);
+ }
gfn_lock(p2m, gfn, 0);
@@ -1028,7 +1032,11 @@ int clear_identity_p2m_entry(struct doma
int ret;
if ( !paging_mode_translate(d) )
- return 0;
+ {
+ if ( !need_iommu(d) )
+ return 0;
+ return iommu_unmap_page(d, gfn);
+ }
gfn_lock(p2m, gfn, 0);
Attachment:
x86-PV-IOMMU-identmap.patch _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |