linux/arch/s390/mm
Gerald Schaefer ba925fa350 s390/gmap: improve THP splitting
During s390_enable_sie(), we need to take care of splitting all qemu user
process THP mappings. This is currently done with follow_page(FOLL_SPLIT),
by simply iterating over all vma ranges, with PAGE_SIZE increment.

This logic is sub-optimal and can result in a lot of unnecessary overhead,
especially when using qemu and ASAN with large shadow map. Ilya reported
significant system slow-down with one CPU busy for a long time and overall
unresponsiveness.

Fix this by using walk_page_vma() and directly calling split_huge_pmd()
only for present pmds, which greatly reduces overhead.

Cc: <stable@vger.kernel.org> # v5.4+
Reported-by: Ilya Leoshkevich <iii@linux.ibm.com>
Tested-by: Ilya Leoshkevich <iii@linux.ibm.com>
Acked-by: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Gerald Schaefer <gerald.schaefer@linux.ibm.com>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
2020-08-11 18:16:13 +02:00
..
cmm.c mm: remove unneeded includes of <asm/pgalloc.h> 2020-08-07 11:33:26 -07:00
dump_pagetables.c mm: don't include asm/pgtable.h if linux/mm.h is already included 2020-06-09 09:39:13 -07:00
extmem.c s390/extmem: remove stale -ENOSPC comment and handling 2020-07-03 10:49:16 +02:00
fault.c s390/kernel: expand exception table logic to allow new handling options 2020-07-20 10:55:50 +02:00
gmap.c s390/gmap: improve THP splitting 2020-08-11 18:16:13 +02:00
hugetlbpage.c s390/mm: fix huge pte soft dirty copying 2020-07-09 15:18:23 +02:00
init.c mm/sparse: cleanup the code surrounding memory_present() 2020-08-07 11:33:27 -07:00
kasan_init.c mm: reorder includes after introduction of linux/pgtable.h 2020-06-09 09:39:13 -07:00
maccess.c s390/maccess: add no DAT mode to kernel_write 2020-06-29 16:26:36 +02:00
Makefile s390/mm: convert to the generic get_user_pages_fast code 2019-04-23 16:30:04 +02:00
mmap.c mm: remove unneeded includes of <asm/pgalloc.h> 2020-08-07 11:33:26 -07:00
page-states.c s390/cmma: reuse kstrtobool for option value parsing 2019-08-26 12:51:18 +02:00
pageattr.c mm: consolidate pte_index() and pte_offset_*() definitions 2020-06-09 09:39:14 -07:00
pgalloc.c mmap locking API: convert mmap_sem comments 2020-06-09 09:39:14 -07:00
pgtable.c mm: remove unneeded includes of <asm/pgalloc.h> 2020-08-07 11:33:26 -07:00
vmem.c s390/vmemmap: coding style updates 2020-07-27 10:34:19 +02:00