aboutsummaryrefslogtreecommitdiff
path: root/arch/powerpc/sysdev/dart_iommu.c
diff options
context:
space:
mode:
authorAlexey Kardashevskiy <[email protected]>2021-02-16 14:33:06 +1100
committerMichael Ellerman <[email protected]>2021-04-23 01:38:04 +1000
commit7f1fa82d79947dfabb4046e1d787da9db2bc1c20 (patch)
treec5b4c0c664a80359ec39102d2efdab3b6ca581bc /arch/powerpc/sysdev/dart_iommu.c
parent0db11461677aa5105b9ebbd939aee0ceb77a988b (diff)
powerpc/iommu: Allocate it_map by vmalloc
The IOMMU table uses the it_map bitmap to keep track of allocated DMA pages. This has always been a contiguous array allocated at either the boot time or when a passed through device is returned to the host OS. The it_map memory is allocated by alloc_pages() which allocates contiguous physical memory. Such allocation method occasionally creates a problem when there is no big chunk of memory available (no free memory or too fragmented). On powernv/ioda2 the default DMA window requires 16MB for it_map. This replaces alloc_pages_node() with vzalloc_node() which allocates contiguous block but in virtual memory. This should reduce changes of failure but should not cause other behavioral changes as it_map is only used by the kernel's DMA hooks/api when MMU is on. Signed-off-by: Alexey Kardashevskiy <[email protected]> Reviewed-by: David Gibson <[email protected]> Signed-off-by: Michael Ellerman <[email protected]> Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'arch/powerpc/sysdev/dart_iommu.c')
0 files changed, 0 insertions, 0 deletions