lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20250224125414.2184-2-ceggers@arri.de>
Date: Mon, 24 Feb 2025 13:54:14 +0100
From: Christian Eggers <ceggers@...i.de>
To: Russell King <linux@...linux.org.uk>, Yuntao Liu <liuyuntao12@...wei.com>,
	"Russell King (Oracle)" <rmk+kernel@...linux.org.uk>, Arnd Bergmann
	<arnd@...db.de>, Linus Walleij <linus.walleij@...aro.org>, Greg Kroah-Hartman
	<gregkh@...uxfoundation.org>, Catalin Marinas <catalin.marinas@....com>,
	Nathan Chancellor <nathan@...nel.org>, <linux-arm-kernel@...ts.infradead.org>
CC: <linux-kernel@...r.kernel.org>, Christian Eggers <ceggers@...i.de>
Subject: [PATCH v2 2/2] ARM: avoid that vectors are removed during linker garbage collection

Without this, the vectors are removed if LD_DEAD_CODE_DATA_ELIMINATION
is enabled.  At startup, the CPU (silently) hangs in the undefined
instruction exception as soon as the first timer interrupt arrives.

Fixes: ed0f94102251 ("ARM: 9404/1: arm32: enable HAVE_LD_DEAD_CODE_DATA_ELIMINATION")
Signed-off-by: Christian Eggers <ceggers@...i.de>
---
v2:
- changed patch title

 arch/arm/include/asm/vmlinux.lds.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/arch/arm/include/asm/vmlinux.lds.h b/arch/arm/include/asm/vmlinux.lds.h
index 7ba309f826f9..288057e07e69 100644
--- a/arch/arm/include/asm/vmlinux.lds.h
+++ b/arch/arm/include/asm/vmlinux.lds.h
@@ -126,16 +126,16 @@
 	/* Note: The LLD linker seems not to support marking input */	\
 	/* sections with KEEP() inside a OVERLAY statement */		\
 	.vectors 0xffff0000 : AT (__vectors_lma) {			\
-			*(.vectors)					\
+			KEEP(*(.vectors))				\
 	}								\
 	.vectors.bhb.loop8 0xffff0000 : AT (__vectors_lma +		\
 		SIZEOF(.vectors)) {					\
-			*(.vectors.bhb.loop8)				\
+			KEEP(*(.vectors.bhb.loop8))			\
 	}								\
 	.vectors.bhb.bpiall 0xffff0000 : AT (__vectors_lma +		\
 		SIZEOF(.vectors) +					\
 		SIZEOF(.vectors.bhb.loop8)) {				\
-			*(.vectors.bhb.bpiall)				\
+			KEEP(*(.vectors.bhb.bpiall))			\
 	}								\
 	ARM_LMA(__vectors, .vectors);					\
 	ARM_LMA(__vectors_bhb_loop8, .vectors.bhb.loop8);		\
-- 
2.43.0


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ