diff options
author | David Vrabel <david.vrabel@citrix.com> | 2015-03-11 14:49:56 +0000 |
---|---|---|
committer | David Vrabel <david.vrabel@citrix.com> | 2015-03-16 14:49:15 +0000 |
commit | 628c28eefd6f2cef03b212081b466ae43fd093a3 (patch) | |
tree | edcde5040badd2068efe925f8253961e0ca71c48 /include/xen | |
parent | b3b06c7eb7820cea5c15f9faa4964044284c5399 (diff) | |
download | op-kernel-dev-628c28eefd6f2cef03b212081b466ae43fd093a3.zip op-kernel-dev-628c28eefd6f2cef03b212081b466ae43fd093a3.tar.gz |
xen: unify foreign GFN map/unmap for auto-xlated physmap guests
Auto-translated physmap guests (arm, arm64 and x86 PVHVM/PVH) map and
unmap foreign GFNs using the same method (updating the physmap).
Unify the two arm and x86 implementations into one commont one.
Note that on arm and arm64, the correct error code will be returned
(instead of always -EFAULT) and map/unmap failure warnings are no
longer printed. These changes are required if the foreign domain is
paging (-ENOENT failures are expected and must be propagated up to the
caller).
Signed-off-by: David Vrabel <david.vrabel@citrix.com>
Reviewed-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Diffstat (limited to 'include/xen')
-rw-r--r-- | include/xen/xen-ops.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/xen/xen-ops.h b/include/xen/xen-ops.h index 8333821..9eb88a4 100644 --- a/include/xen/xen-ops.h +++ b/include/xen/xen-ops.h @@ -34,6 +34,14 @@ int xen_remap_domain_mfn_range(struct vm_area_struct *vma, struct page **pages); int xen_unmap_domain_mfn_range(struct vm_area_struct *vma, int numpgs, struct page **pages); +int xen_xlate_remap_gfn_range(struct vm_area_struct *vma, + unsigned long addr, + xen_pfn_t gfn, int nr, + pgprot_t prot, + unsigned domid, + struct page **pages); +int xen_xlate_unmap_gfn_range(struct vm_area_struct *vma, + int nr, struct page **pages); bool xen_running_on_version_or_later(unsigned int major, unsigned int minor); |