aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/lib/code-patching.c
diff options
context:
space:
mode:
authorLeonardo Bras <[email protected]>2021-04-20 04:54:04 +0000
committerMichael Ellerman <[email protected]>2021-04-21 12:52:31 +0000
commita9d2f9bb225fd2a764aef57738ab6c7f38d782ae (patch)
treec97668fa571d9b4bac903f003d2ec521d56e5a4a /arch/powerpc/lib/code-patching.c
parentpowerpc/kvm: Fix PR KVM with KUAP/MEM_KEYS enabled (diff)
downloadkernel-a9d2f9bb225fd2a764aef57738ab6c7f38d782ae.tar.gz
kernel-a9d2f9bb225fd2a764aef57738ab6c7f38d782ae.zip
powerpc/pseries/iommu: Fix window size for direct mapping with pmem
As of today, if the DDW is big enough to fit (1 << MAX_PHYSMEM_BITS) it's possible to use direct DMA mapping even with pmem region. But, if that happens, the window size (len) is set to (MAX_PHYSMEM_BITS - page_shift) instead of MAX_PHYSMEM_BITS, causing a pagesize times smaller DDW to be created, being insufficient for correct usage. Fix this so the correct window size is used in this case. Fixes: bf6e2d562bbc4 ("powerpc/dma: Fallback to dma_ops when persistent memory present") Signed-off-by: Leonardo Bras <[email protected]> Reviewed-by: Alexey Kardashevskiy <[email protected]> Signed-off-by: Michael Ellerman <[email protected]> Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'arch/powerpc/lib/code-patching.c')
0 files changed, 0 insertions, 0 deletions