[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH v3 1/2] swiotlb-xen: implement xen_swiotlb_dma_mmap callback



On Tue, Jan 31, 2017 at 08:30:25PM +0200, Andrii Anisov wrote:
> From: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
> 
> This function creates userspace mapping for the DMA-coherent memory.
> 
> Signed-off-by: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
> Signed-off-by: Oleksandr Dmytryshyn <oleksandr.dmytryshyn@xxxxxxxxxxxxxxx>
> Signed-off-by: Andrii Anisov <andrii_anisov@xxxxxxxx>
> ---
>  arch/arm/xen/mm.c         |  1 +
>  drivers/xen/swiotlb-xen.c | 18 ++++++++++++++++++
>  include/xen/swiotlb-xen.h |  5 +++++
>  3 files changed, 24 insertions(+)
> 
> diff --git a/arch/arm/xen/mm.c b/arch/arm/xen/mm.c
> index bd62d94..cd1684e 100644
> --- a/arch/arm/xen/mm.c
> +++ b/arch/arm/xen/mm.c
> @@ -198,6 +198,7 @@ static struct dma_map_ops xen_swiotlb_dma_ops = {
>       .unmap_page = xen_swiotlb_unmap_page,
>       .dma_supported = xen_swiotlb_dma_supported,
>       .set_dma_mask = xen_swiotlb_set_dma_mask,
> +     .mmap = xen_swiotlb_dma_mmap,
>  };
>  
>  int __init xen_mm_init(void)
> diff --git a/drivers/xen/swiotlb-xen.c b/drivers/xen/swiotlb-xen.c
> index f8afc6d..8ac36b4 100644
> --- a/drivers/xen/swiotlb-xen.c
> +++ b/drivers/xen/swiotlb-xen.c
> @@ -681,3 +681,21 @@ xen_swiotlb_set_dma_mask(struct device *dev, u64 
> dma_mask)
>       return 0;
>  }
>  EXPORT_SYMBOL_GPL(xen_swiotlb_set_dma_mask);
> +
> +/*
> + * Create userspace mapping for the DMA-coherent memory.
> + * Following function should be called with the local pages only.

What does 'local pages' mean?

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.