mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
iommu/vt-d: correct flush_unmaps pfn usage
Change flush_unmaps() to correctly pass iommu_flush_iotlb_psi() dma addresses. (x86_64 mm and dma have the same size for pages at the moment, but this usage improves consistency.) Signed-off-by: Omer Peleg <[email protected]> [[email protected]: rebased and reworded the commit message] Signed-off-by: Adam Morrison <[email protected]> Reviewed-by: Shaohua Li <[email protected]> Reviewed-by: Ben Serebrin <[email protected]> Signed-off-by: David Woodhouse <[email protected]>
This commit is contained in:
parent
aa4732406e
commit
f5c0c08b1e
1 changed files with 2 additions and 1 deletions
|
|
@ -3548,7 +3548,8 @@ static void flush_unmaps(struct deferred_flush_data *flush_data)
|
|||
/* On real hardware multiple invalidations are expensive */
|
||||
if (cap_caching_mode(iommu->cap))
|
||||
iommu_flush_iotlb_psi(iommu, domain,
|
||||
iova->pfn_lo, iova_size(iova),
|
||||
mm_to_dma_pfn(iova->pfn_lo),
|
||||
mm_to_dma_pfn(iova_size(iova)),
|
||||
!freelist, 0);
|
||||
else {
|
||||
mask = ilog2(mm_to_dma_pfn(iova_size(iova)));
|
||||
|
|
|
|||
Loading…
Reference in a new issue