[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH v2 3/3] x86/mm: Fix p2m_set_suppress_ve
On a new altp2m view the p2m_set_suppress_ve() func will fail with invalid mfn from p2m->get_entry() if p2m->set_entry() was not called before. This patch solves the problem by getting the mfn from hostp2m. Signed-off-by: Alexandru Isaila <aisaila@xxxxxxxxxxxxxxx> --- xen/arch/x86/mm/p2m.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/xen/arch/x86/mm/p2m.c b/xen/arch/x86/mm/p2m.c index 1f852694ff..6dee0052f8 100644 --- a/xen/arch/x86/mm/p2m.c +++ b/xen/arch/x86/mm/p2m.c @@ -2974,6 +2974,7 @@ int p2m_set_suppress_ve(struct domain *d, gfn_t gfn, bool suppress_ve, p2m_access_t a; p2m_type_t t; int rc; + bool found_in_hostp2m; if ( altp2m_idx > 0 ) { @@ -2991,7 +2992,7 @@ int p2m_set_suppress_ve(struct domain *d, gfn_t gfn, bool suppress_ve, if ( ap2m ) p2m_lock(ap2m); - mfn = p2m->get_entry(p2m, gfn, &t, &a, 0, NULL, NULL); + mfn = altp2m_get_gfn_type_access(p2m, gfn, &t, &a, NULL, &found_in_hostp2m); if ( !mfn_valid(mfn) ) { rc = -ESRCH; -- 2.17.1 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |