Re: [PATCH v3 5/5] dma-iommu: account for min_align_mask

2021-08-12 Thread Robin Murphy
On 2021-08-12 02:45, David Stevens wrote: On Thu, Aug 12, 2021 at 4:12 AM Robin Murphy wrote: On 2021-08-11 03:42, David Stevens wrote: From: David Stevens For devices which set min_align_mask, swiotlb preserves the offset of the original physical address within that mask. Since

Re: [PATCH v3 5/5] dma-iommu: account for min_align_mask

2021-08-11 Thread David Stevens
On Thu, Aug 12, 2021 at 4:12 AM Robin Murphy wrote: > > On 2021-08-11 03:42, David Stevens wrote: > > From: David Stevens > > > > For devices which set min_align_mask, swiotlb preserves the offset of > > the original physical address within that mask. Since __iommu_dma_map > > accounts for

Re: [PATCH v3 5/5] dma-iommu: account for min_align_mask

2021-08-11 Thread Robin Murphy
On 2021-08-11 03:42, David Stevens wrote: From: David Stevens For devices which set min_align_mask, swiotlb preserves the offset of the original physical address within that mask. Since __iommu_dma_map accounts for non-aligned addresses, passing a non-aligned swiotlb address with the swiotlb

RE: [PATCH v3 5/5] dma-iommu: account for min_align_mask

2021-08-11 Thread Mi, Dapeng1
> -Original Message- > From: iommu On Behalf Of > David Stevens > Sent: Wednesday, August 11, 2021 10:43 AM > To: Robin Murphy ; Will Deacon > Cc: linux-ker...@vger.kernel.org; Tom Murphy ; > iommu@lists.linux-foundation.org; David Stevens > Subject: [PATCH v3

[PATCH v3 5/5] dma-iommu: account for min_align_mask

2021-08-10 Thread David Stevens
From: David Stevens For devices which set min_align_mask, swiotlb preserves the offset of the original physical address within that mask. Since __iommu_dma_map accounts for non-aligned addresses, passing a non-aligned swiotlb address with the swiotlb aligned size results in the offset being