Revert "powerpc/pseries/iommu: Don't use dma_iommu_ops on secure guests"
authorRam Pai <linuxram@us.ibm.com>
Mon, 16 Dec 2019 04:19:21 +0000 (15:19 +1100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 14 Feb 2020 21:34:16 +0000 (16:34 -0500)
commit6d7edac1469eddb98d66947f3cdb726bc5e695d2
tree8ecbebcf6a02dcb904f5c1f0ef4d1245c117dc5b
parent45c764da005af27caad9789e8e013fcaa6126ade
Revert "powerpc/pseries/iommu: Don't use dma_iommu_ops on secure guests"

commit d862b44133b7a1d7de25288e09eabf4df415e971 upstream.

This reverts commit edea902c1c1efb855f77e041f9daf1abe7a9768a.

At the time the change allowed direct DMA ops for secure VMs; however
since then we switched on using SWIOTLB backed with IOMMU (direct mapping)
and to make this work, we need dma_iommu_ops which handles all cases
including TCE mapping I/O pages in the presence of an IOMMU.

Fixes: edea902c1c1e ("powerpc/pseries/iommu: Don't use dma_iommu_ops on secure guests")
Signed-off-by: Ram Pai <linuxram@us.ibm.com>
[aik: added "revert" and "fixes:"]
Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Reviewed-by: Thiago Jung Bauermann <bauerman@linux.ibm.com>
Tested-by: Thiago Jung Bauermann <bauerman@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20191216041924.42318-2-aik@ozlabs.ru
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/powerpc/platforms/pseries/iommu.c