iommu/mediatek: Use gather to achieve the tlb range flush
authorYong Wu <yong.wu@mediatek.com>
Mon, 4 Nov 2019 07:01:04 +0000 (15:01 +0800)
committerJoerg Roedel <jroedel@suse.de>
Mon, 11 Nov 2019 14:02:34 +0000 (15:02 +0100)
commita7a04ea34e1c483d10d3e72250ff5503b1076fe3
treebcee15eff9401350fa569ced4209d3f5990087a9
parentda3cc91b8db403728cde03c8a95cba268d8cbf1b
iommu/mediatek: Use gather to achieve the tlb range flush

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.

Suggested-by: Tomasz Figa <tfiga@chromium.org>
Signed-off-by: Yong Wu <yong.wu@mediatek.com>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/iommu/mtk_iommu.c