Re: [PATCH v3 3/7] iommu/mediatek: Use gather to achieve the tlb range flush

2019-10-15 Thread Robin Murphy
On 15/10/2019 06:26, Yong Wu wrote: On Mon, 2019-10-14 at 15:21 +0100, Robin Murphy wrote: On 14/10/2019 07:38, Yong Wu wrote: Use the iommu_gather mechanism to achieve the tlb range flush. Gather the iova range in the "tlb_add_page", then flush the merged iova range in iotlb_sync. Note: If io

Re: [PATCH v3 3/7] iommu/mediatek: Use gather to achieve the tlb range flush

2019-10-14 Thread Yong Wu
On Mon, 2019-10-14 at 15:21 +0100, Robin Murphy wrote: > On 14/10/2019 07:38, Yong Wu wrote: > > Use the iommu_gather mechanism to achieve the tlb range flush. > > Gather the iova range in the "tlb_add_page", then flush the merged iova > > range in iotlb_sync. > > > > Note: If iotlb_sync comes fro

Re: [PATCH v3 3/7] iommu/mediatek: Use gather to achieve the tlb range flush

2019-10-14 Thread Robin Murphy
On 14/10/2019 07:38, Yong Wu wrote: Use the iommu_gather mechanism to achieve the tlb range flush. Gather the iova range in the "tlb_add_page", then flush the merged iova range in iotlb_sync. Note: If iotlb_sync comes from iommu_iotlb_gather_add_page, we have to avoid retry the lock since the sp

[PATCH v3 3/7] iommu/mediatek: Use gather to achieve the tlb range flush

2019-10-13 Thread Yong Wu
Use the iommu_gather mechanism to achieve the tlb range flush. Gather the iova range in the "tlb_add_page", then flush the merged iova range in iotlb_sync. Note: If iotlb_sync comes from iommu_iotlb_gather_add_page, we have to avoid retry the lock since the spinlock have already been acquired. Su