Current npt and shadow code to get an entry will always return INVALID_MFN for foreign entries. Allow to return the entry mfn for foreign entries, like it's done for grant table entries.
Signed-off-by: Roger Pau Monné <[email protected]> --- Cc: George Dunlap <[email protected]> Cc: Jan Beulich <[email protected]> Cc: Andrew Cooper <[email protected]> Cc: Wei Liu <[email protected]> --- xen/arch/x86/mm/p2m-pt.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/xen/arch/x86/mm/p2m-pt.c b/xen/arch/x86/mm/p2m-pt.c index 6238043aa6..973261a3a8 100644 --- a/xen/arch/x86/mm/p2m-pt.c +++ b/xen/arch/x86/mm/p2m-pt.c @@ -852,7 +852,8 @@ pod_retry_l1: unmap_domain_page(l1e); ASSERT(mfn_valid(mfn) || !p2m_is_ram(*t) || p2m_is_paging(*t)); - return (p2m_is_valid(*t) || p2m_is_grant(*t)) ? mfn : INVALID_MFN; + return (p2m_is_valid(*t) || p2m_is_grant(*t) || p2m_is_foreign(*t)) + ? mfn : INVALID_MFN; } static void p2m_pt_change_entry_type_global(struct p2m_domain *p2m, -- 2.20.1 _______________________________________________ Xen-devel mailing list [email protected] https://lists.xenproject.org/mailman/listinfo/xen-devel
