[PATCH] riscv: unconditionally select ARCH_KEEP_MEMBLOCK

Han Gao posted 1 patch 5 days, 8 hours ago
arch/riscv/Kconfig | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
[PATCH] riscv: unconditionally select ARCH_KEEP_MEMBLOCK
Posted by Han Gao 5 days, 8 hours ago
Select ARCH_KEEP_MEMBLOCK unconditionally. kexec requires memblock
to be kept after boot to initialize the secondary kernel. Device
Tree platforms also need this for kexec support.

Signed-off-by: Han Gao <gaohan@iscas.ac.cn>
---
 arch/riscv/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/riscv/Kconfig b/arch/riscv/Kconfig
index c5754942cf85..e2a052257176 100644
--- a/arch/riscv/Kconfig
+++ b/arch/riscv/Kconfig
@@ -55,7 +55,7 @@ config RISCV
 	select ARCH_HAS_UBSAN
 	select ARCH_HAS_VDSO_ARCH_DATA if HAVE_GENERIC_VDSO
 	select ARCH_HAVE_NMI_SAFE_CMPXCHG
-	select ARCH_KEEP_MEMBLOCK if ACPI
+	select ARCH_KEEP_MEMBLOCK
 	select ARCH_MHP_MEMMAP_ON_MEMORY_ENABLE	if 64BIT && MMU
 	select ARCH_OPTIONAL_KERNEL_RWX if ARCH_HAS_STRICT_KERNEL_RWX
 	select ARCH_OPTIONAL_KERNEL_RWX_DEFAULT
-- 
2.47.3
Re: [PATCH] riscv: unconditionally select ARCH_KEEP_MEMBLOCK
Posted by Paul Walmsley 3 days, 3 hours ago
On Wed, 20 May 2026, Han Gao wrote:

> Select ARCH_KEEP_MEMBLOCK unconditionally. kexec requires memblock
> to be kept after boot to initialize the secondary kernel. Device
> Tree platforms also need this for kexec support.
> 
> Signed-off-by: Han Gao <gaohan@iscas.ac.cn>

Thanks for the patch.  If this patch is just about kexec, shouldn't 
ARCH_SELECTS_KEXEC just be changed to select ARCH_KEEP_MEMBLOCK?


- Paul