linux-loongson/arch/powerpc/mm/book3s32
Guo Weikang c6f239796b mm/memblock: add memblock_alloc_or_panic interface
Before SLUB initialization, various subsystems used memblock_alloc to
allocate memory.  In most cases, when memory allocation fails, an
immediate panic is required.  To simplify this behavior and reduce
repetitive checks, introduce `memblock_alloc_or_panic`.  This function
ensures that memory allocation failures result in a panic automatically,
improving code readability and consistency across subsystems that require
this behavior.

[guoweikang.kernel@gmail.com: arch/s390: save_area_alloc default failure behavior changed to panic]
  Link: https://lkml.kernel.org/r/20250109033136.2845676-1-guoweikang.kernel@gmail.com
  Link: https://lore.kernel.org/lkml/Z2fknmnNtiZbCc7x@kernel.org/
Link: https://lkml.kernel.org/r/20250102072528.650926-1-guoweikang.kernel@gmail.com
Signed-off-by: Guo Weikang <guoweikang.kernel@gmail.com>
Acked-by: Geert Uytterhoeven <geert@linux-m68k.org>	[m68k]
Reviewed-by: Alexander Gordeev <agordeev@linux.ibm.com>	[s390]
Acked-by: Mike Rapoport (Microsoft) <rppt@kernel.org>
Cc: Alexander Gordeev <agordeev@linux.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2025-01-25 20:22:38 -08:00
..
hash_low.S powerpc/32s: Introduce _PAGE_READ and remove _PAGE_USER 2023-10-19 17:12:47 +11:00
kuap.c powerpc/kuap: Simplify KUAP lock/unlock on BOOK3S/32 2023-08-02 22:22:18 +10:00
Makefile powerpc/kuep: Remove 'nosmep' boot time parameter except for book3s/64 2021-12-09 22:41:18 +11:00
mmu_context.c powerpc/kuap: Fold kuep_is_disabled() into its only user 2023-08-02 22:22:17 +10:00
mmu.c mm/memblock: add memblock_alloc_or_panic interface 2025-01-25 20:22:38 -08:00
nohash_low.S powerpc/32s: Move _tlbie() and _tlbia() in a new file 2020-12-09 16:46:55 +11:00
tlb.c powerpc: remove mmap linked list walks 2022-09-26 19:46:19 -07:00