1
0
Fork 0
alistair23-linux/arch/s390/mm
Gerald Schaefer 4db28111b2 s390/gmap: improve THP splitting
commit ba925fa350 upstream.

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>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-08-19 08:16:29 +02:00
..
Makefile s390/mm: convert to the generic get_user_pages_fast code 2019-04-23 16:30:04 +02:00
cmm.c s390/cmm: fix information leak in cmm_timeout_handler() 2019-10-31 17:26:48 +01:00
dump_pagetables.c s390/mm: fix dump_pagetables top level page table walking 2019-08-06 13:58:34 +02:00
extmem.c s390/extmem: use refcount_t for refcount 2019-08-21 12:41:43 +02:00
fault.c s390/mm: add fallthrough annotations 2019-07-29 18:05:03 +02:00
gmap.c s390/gmap: improve THP splitting 2020-08-19 08:16:29 +02:00
hugetlbpage.c s390/mm: fix huge pte soft dirty copying 2020-07-16 08:16:47 +02:00
init.c mm/memory_hotplug: shrink zones when offlining memory 2020-01-09 10:19:56 +01:00
kasan_init.c s390/kasan: add kdump support 2019-08-29 15:34:58 +02:00
maccess.c s390/maccess: add no DAT mode to kernel_write 2020-07-16 08:16:48 +02:00
mmap.c s390/mm: mmap base does not depend on ADDR_NO_RANDOMIZE personality 2019-06-04 15:03:53 +02:00
page-states.c s390/cmma: reuse kstrtobool for option value parsing 2019-08-26 12:51:18 +02:00
pageattr.c s390/mm: Clear huge page storage keys on enable_skey 2018-07-30 11:20:18 +01:00
pgalloc.c s390/mm: fix page table upgrade vs 2ndary address mode accesses 2020-04-29 16:33:25 +02:00
pgtable.c s390/mm: silence compiler warning when compiling without CONFIG_PGSTE 2019-04-10 17:48:28 +02:00
vmem.c s390: prevent leaking kernel address in BEAR 2020-04-13 10:48:06 +02:00