linux/arch/powerpc
Alexey Kardashevskiy 7a3a4d7638 powerpc/mm_iommu: Allow pinning large regions
When called with vmas_arg==NULL, get_user_pages_longterm() allocates
an array of nr_pages*8 which can easily get greater that the max order,
for example, registering memory for a 256GB guest does this and fails
in __alloc_pages_nodemask().

This adds a loop over chunks of entries to fit the max order limit.

Fixes: 678e174c4c ("powerpc/mm/iommu: allow migration of cma allocated pages during mm_iommu_do_alloc", 2019-03-05)
Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
2019-04-17 21:36:51 +10:00
..
boot Kbuild updates for v5.1 2019-03-10 17:48:21 -07:00
configs powerpc/mm/radix: Make Radix require HUGETLB_PAGE 2019-04-17 18:50:26 +10:00
crypto powerpc updates for 4.19 2018-08-17 11:32:50 -07:00
include powerpc/mm: Define MAX_PHYSMEM_BITS for all 64-bit configs 2019-04-10 14:45:57 +10:00
kernel powerpc/64s/radix: Fix radix segment exception handling 2019-04-08 21:46:11 +10:00
kvm ARM: some cleanups, direct physical timer assignment, cache sanitization 2019-03-15 15:00:28 -07:00
lib powerpc/64: Fix memcmp reading past the end of src/dest 2019-03-25 23:33:26 +11:00
math-emu powerpc: math-emu: remove unneeded header search paths 2019-01-14 20:39:27 +11:00
mm powerpc/mm_iommu: Allow pinning large regions 2019-04-17 21:36:51 +10:00
net powerpc updates for 5.1 2019-03-07 12:56:26 -08:00
oprofile Remove 'type' argument from access_ok() function 2019-01-03 18:57:57 -08:00
perf powerpc updates for 5.1 2019-03-07 12:56:26 -08:00
platforms powerpc/mm/radix: Make Radix require HUGETLB_PAGE 2019-04-17 18:50:26 +10:00
purgatory powerpc updates for 4.19 2018-08-17 11:32:50 -07:00
sysdev treewide: add checks for the return value of memblock_alloc*() 2019-03-12 10:04:02 -07:00
tools powerpc/tools/checkpatch: Ignore DT_SPLIT_BINDING_PATCH 2018-12-04 19:45:01 +11:00
xmon powerpc/xmon: Fix opcode being uninitialized in print_insn_powerpc 2019-02-26 23:55:22 +11:00
Kbuild powerpc: Add -Werror at arch/powerpc level 2018-10-19 00:56:17 +11:00
Kconfig DMA mapping updates for 5.1 2019-03-10 11:54:48 -07:00
Kconfig.debug powerpc: Move page table dump files in a dedicated subdirectory 2019-02-22 22:29:22 +11:00
Makefile powerpc/32: Remove CURRENT_THREAD_INFO and rename TI_CPU 2019-02-23 22:31:40 +11:00
Makefile.postlink