#ifdefined(CONFIG_XEN_PV) int xen_remap_pfn(struct vm_area_struct *vma, unsignedlong addr,
xen_pfn_t *pfn, int nr, int *err_ptr, pgprot_t prot, unsignedint domid, bool no_translate); #else staticinlineint xen_remap_pfn(struct vm_area_struct *vma, unsignedlong addr,
xen_pfn_t *pfn, int nr, int *err_ptr,
pgprot_t prot, unsignedint domid, bool no_translate)
{
BUG(); return 0;
} #endif
struct vm_area_struct;
#ifdef CONFIG_XEN_AUTO_XLATE int xen_xlate_remap_gfn_array(struct vm_area_struct *vma, unsignedlong addr,
xen_pfn_t *gfn, int nr, int *err_ptr, pgprot_t prot, unsignedint domid, struct page **pages); int xen_xlate_unmap_gfn_range(struct vm_area_struct *vma, int nr, struct page **pages); #else /* * These two functions are called from arch/x86/xen/mmu.c and so stubs * are needed for a configuration not specifying CONFIG_XEN_AUTO_XLATE.
*/ staticinlineint xen_xlate_remap_gfn_array(struct vm_area_struct *vma, unsignedlong addr,
xen_pfn_t *gfn, int nr, int *err_ptr, pgprot_t prot, unsignedint domid, struct page **pages)
{ return -EOPNOTSUPP;
}
int xen_remap_vma_range(struct vm_area_struct *vma, unsignedlong addr, unsignedlong len);
/* * xen_remap_domain_gfn_array() - map an array of foreign frames by gfn * @vma: VMA to map the pages into * @addr: Address at which to map the pages * @gfn: Array of GFNs to map * @nr: Number entries in the GFN array * @err_ptr: Returns per-GFN error status. * @prot: page protection mask * @domid: Domain owning the pages * @pages: Array of pages if this domain has an auto-translated physmap * * @gfn and @err_ptr may point to the same buffer, the GFNs will be * overwritten by the error codes after they are mapped. * * Returns the number of successfully mapped frames, or a -ve error * code.
*/ staticinlineint xen_remap_domain_gfn_array(struct vm_area_struct *vma, unsignedlong addr,
xen_pfn_t *gfn, int nr, int *err_ptr, pgprot_t prot, unsignedint domid, struct page **pages)
{ if (xen_feature(XENFEAT_auto_translated_physmap)) return xen_xlate_remap_gfn_array(vma, addr, gfn, nr, err_ptr,
prot, domid, pages);
/* We BUG_ON because it's a programmer error to pass a NULL err_ptr, * and the consequences later is quite hard to detect what the actual * cause of "wrong memory was mapped in".
*/
BUG_ON(err_ptr == NULL); return xen_remap_pfn(vma, addr, gfn, nr, err_ptr, prot, domid, false);
}
/* * xen_remap_domain_mfn_array() - map an array of foreign frames by mfn * @vma: VMA to map the pages into * @addr: Address at which to map the pages * @mfn: Array of MFNs to map * @nr: Number entries in the MFN array * @err_ptr: Returns per-MFN error status. * @prot: page protection mask * @domid: Domain owning the pages * * @mfn and @err_ptr may point to the same buffer, the MFNs will be * overwritten by the error codes after they are mapped. * * Returns the number of successfully mapped frames, or a -ve error * code.
*/ staticinlineint xen_remap_domain_mfn_array(struct vm_area_struct *vma, unsignedlong addr, xen_pfn_t *mfn, int nr, int *err_ptr,
pgprot_t prot, unsignedint domid)
{ if (xen_feature(XENFEAT_auto_translated_physmap)) return -EOPNOTSUPP;
/* xen_remap_domain_gfn_range() - map a range of foreign frames * @vma: VMA to map the pages into * @addr: Address at which to map the pages * @gfn: First GFN to map. * @nr: Number frames to map * @prot: page protection mask * @domid: Domain owning the pages * @pages: Array of pages if this domain has an auto-translated physmap * * Returns the number of successfully mapped frames, or a -ve error * code.
*/ staticinlineint xen_remap_domain_gfn_range(struct vm_area_struct *vma, unsignedlong addr,
xen_pfn_t gfn, int nr,
pgprot_t prot, unsignedint domid, struct page **pages)
{ if (xen_feature(XENFEAT_auto_translated_physmap)) return -EOPNOTSUPP;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.