powerpc/pseries/dma: Enable SWIOTLB
authorAlexey Kardashevskiy <aik@ozlabs.ru>
Tue, 7 May 2019 06:25:59 +0000 (16:25 +1000)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 3 Jul 2019 05:19:35 +0000 (15:19 +1000)
commit1a047cc7e53cb10e4706c09f6e92b2fa911a2bf2
treef7ec84bc255ca2d4e135f52540851d429d2573e4
parentefd176a04bef41aab5b3087e977fea2b69915174
powerpc/pseries/dma: Enable SWIOTLB

So far the pseries platforms has always been using IOMMU making
SWIOTLB unnecessary. Now we want secure guests which means devices can
only access certain areas of guest physical memory; we are going to
use SWIOTLB for this purpose.

This allows SWIOTLB for pseries. By default there is no change in
behavior.

This enables SWIOTLB when the "swiotlb" kernel parameter is set to
"force".

With the SWIOTLB enabled, the kernel creates a directly mapped DMA
window (using the usual DDW mechanism) and implements SWIOTLB on top
of that.

Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/platforms/pseries/Kconfig
arch/powerpc/platforms/pseries/setup.c