From: Rolf Eike Beer Date: Tue, 14 Jan 2025 13:45:38 +0000 (+0100) Subject: ARM: 9439/1: arm32: simplify ARM_MMU_KEEP usage X-Git-Tag: v6.15-rc1~34^2~5 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=f9733aa925d99268e3c1f284d3e62e6a643dcc1d;p=thirdparty%2Fkernel%2Flinux.git ARM: 9439/1: arm32: simplify ARM_MMU_KEEP usage All current users need to add a KEEP() around the argument so the value is actually kept, which doesn't feel very natural and is prone to upcoming bugs as the name suggests that this macro alone already keeps things. Move that directly into the definition. Signed-off-by: Rolf Eike Beer Reviewed-by: Linus Walleij Signed-off-by: Russell King (Oracle) --- diff --git a/arch/arm/include/asm/vmlinux.lds.h b/arch/arm/include/asm/vmlinux.lds.h index d60f6e83a9f70..89697f2047159 100644 --- a/arch/arm/include/asm/vmlinux.lds.h +++ b/arch/arm/include/asm/vmlinux.lds.h @@ -19,7 +19,7 @@ #endif #ifdef CONFIG_MMU -#define ARM_MMU_KEEP(x) x +#define ARM_MMU_KEEP(x) KEEP(x) #define ARM_MMU_DISCARD(x) #else #define ARM_MMU_KEEP(x) diff --git a/arch/arm/kernel/vmlinux-xip.lds.S b/arch/arm/kernel/vmlinux-xip.lds.S index 5eddb75a71740..f2e8d4fac0687 100644 --- a/arch/arm/kernel/vmlinux-xip.lds.S +++ b/arch/arm/kernel/vmlinux-xip.lds.S @@ -63,7 +63,7 @@ SECTIONS . = ALIGN(4); __ex_table : AT(ADDR(__ex_table) - LOAD_OFFSET) { __start___ex_table = .; - ARM_MMU_KEEP(KEEP(*(__ex_table))) + ARM_MMU_KEEP(*(__ex_table)) __stop___ex_table = .; } diff --git a/arch/arm/kernel/vmlinux.lds.S b/arch/arm/kernel/vmlinux.lds.S index de373c6c2ae87..d592a203f9c6b 100644 --- a/arch/arm/kernel/vmlinux.lds.S +++ b/arch/arm/kernel/vmlinux.lds.S @@ -74,7 +74,7 @@ SECTIONS . = ALIGN(4); __ex_table : AT(ADDR(__ex_table) - LOAD_OFFSET) { __start___ex_table = .; - ARM_MMU_KEEP(KEEP(*(__ex_table))) + ARM_MMU_KEEP(*(__ex_table)) __stop___ex_table = .; }