This is a note to let you know that I've just added the patch titled s390/mm: Consider KMSAN modules metadata for paging levels to the 6.12-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: s390-mm-consider-kmsan-modules-metadata-for-paging-l.patch and it can be found in the queue-6.12 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. commit 025f5a1045222edc3b8a26a391636ca98d5dbcdf Author: Vasily Gorbik <gor@xxxxxxxxxxxxx> Date: Tue Dec 10 12:35:34 2024 +0100 s390/mm: Consider KMSAN modules metadata for paging levels [ Upstream commit 282da38b465395c930687974627c24f47ddce5ff ] The calculation determining whether to use three- or four-level paging didn't account for KMSAN modules metadata. Include this metadata in the virtual memory size calculation to ensure correct paging mode selection and avoiding potentially unnecessary physical memory size limitations. Fixes: 65ca73f9fb36 ("s390/mm: define KMSAN metadata for vmalloc and modules") Acked-by: Heiko Carstens <hca@xxxxxxxxxxxxx> Reviewed-by: Alexander Gordeev <agordeev@xxxxxxxxxxxxx> Reviewed-by: Ilya Leoshkevich <iii@xxxxxxxxxxxxx> Signed-off-by: Vasily Gorbik <gor@xxxxxxxxxxxxx> Signed-off-by: Alexander Gordeev <agordeev@xxxxxxxxxxxxx> Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx> diff --git a/arch/s390/boot/startup.c b/arch/s390/boot/startup.c index c8f149ad77e5..c2ee0745f59e 100644 --- a/arch/s390/boot/startup.c +++ b/arch/s390/boot/startup.c @@ -231,6 +231,8 @@ static unsigned long get_vmem_size(unsigned long identity_size, vsize = round_up(SZ_2G + max_mappable, rte_size) + round_up(vmemmap_size, rte_size) + FIXMAP_SIZE + MODULES_LEN + KASLR_LEN; + if (IS_ENABLED(CONFIG_KMSAN)) + vsize += MODULES_LEN * 2; return size_add(vsize, vmalloc_size); }