Re: [PATCH v3 2/5] dma-iommu: fix arch_sync_dma for map

2021-08-12 Thread Robin Murphy
On 2021-08-12 10:21, David Stevens wrote: On Thu, Aug 12, 2021 at 3:47 AM Robin Murphy wrote: On 2021-08-11 03:42, David Stevens wrote: From: David Stevens When calling arch_sync_dma, we need to pass it the memory that's actually being used for dma. When using swiotlb bounce buffers, this

Re: [PATCH v3 2/5] dma-iommu: fix arch_sync_dma for map

2021-08-12 Thread David Stevens
On Thu, Aug 12, 2021 at 3:47 AM Robin Murphy wrote: > > On 2021-08-11 03:42, David Stevens wrote: > > From: David Stevens > > > > When calling arch_sync_dma, we need to pass it the memory that's > > actually being used for dma. When using swiotlb bounce buffers, this is > > the bounce buffer.

Re: [PATCH v3 2/5] dma-iommu: fix arch_sync_dma for map

2021-08-11 Thread Robin Murphy
On 2021-08-11 03:42, David Stevens wrote: From: David Stevens When calling arch_sync_dma, we need to pass it the memory that's actually being used for dma. When using swiotlb bounce buffers, this is the bounce buffer. Move arch_sync_dma into the __iommu_dma_map_swiotlb helper, so it can use

Re: [PATCH v3 2/5] dma-iommu: fix arch_sync_dma for map

2021-08-11 Thread Christoph Hellwig
Looks good, Reviewed-by: Christoph Hellwig ___ iommu mailing list iommu@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/iommu

[PATCH v3 2/5] dma-iommu: fix arch_sync_dma for map

2021-08-10 Thread David Stevens
From: David Stevens When calling arch_sync_dma, we need to pass it the memory that's actually being used for dma. When using swiotlb bounce buffers, this is the bounce buffer. Move arch_sync_dma into the __iommu_dma_map_swiotlb helper, so it can use the bounce buffer address if necessary. This