kernel_samsung_a53x/arch/s390/mm
Gerald Schaefer b64679781a s390/mm: Add cond_resched() to cmm_alloc/free_pages()
[ Upstream commit 131b8db78558120f58c5dc745ea9655f6b854162 ]

Adding/removing large amount of pages at once to/from the CMM balloon
can result in rcu_sched stalls or workqueue lockups, because of busy
looping w/o cond_resched().

Prevent this by adding a cond_resched(). cmm_free_pages() holds a
spin_lock while looping, so it cannot be added directly to the existing
loop. Instead, introduce a wrapper function that operates on maximum 256
pages at once, and add it there.

Signed-off-by: Gerald Schaefer <gerald.schaefer@linux.ibm.com>
Reviewed-by: Heiko Carstens <hca@linux.ibm.com>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-11-23 23:21:49 +01:00
..
cmm.c s390/mm: Add cond_resched() to cmm_alloc/free_pages() 2024-11-23 23:21:49 +01:00
dump_pagetables.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
extmem.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
fault.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
gmap.c s390/mm: Fix storage key clearing for guest huge pages 2024-11-19 11:32:42 +01:00
hugetlbpage.c s390/mm: Fix clearing storage keys for huge pages 2024-11-19 11:32:42 +01:00
init.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
kasan_init.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
maccess.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Makefile Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
mmap.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
page-states.c s390/cmma: fix detection of DAT pages 2024-11-18 12:11:11 +01:00
pageattr.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
pgalloc.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
pgtable.c KVM: s390/mm: Properly reset no-dat 2024-11-18 12:11:46 +01:00
vmem.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00