Thread (21 messages) 21 messages, 4 authors, 2024-03-22

RE: [PATCH v2] ARM: unwind: improve unwinders for noreturn case

From: David Laight <hidden>
Date: 2024-03-22 09:24:49
Also in: linux-hardening, linux-mm, lkml

From: Russell King
Sent: 22 March 2024 00:09

On Thu, Mar 21, 2024 at 11:43:41PM +0100, Ard Biesheuvel wrote:
quoted
Given that this particular issue would just disappear if the compiler
would just insert a BRK after the BL, I'd prefer to explore first
whether we can get this fixed on the compiler side.
Arm32 doesn't have a BRK instruction. What would be appropriate after
the no-return BL would be OS specific.
It would need to depend on what was being compiled.
For the kernel it could be much the same as BUG().
(Probably without any extra data.)
I suspect that arm32 could use 'swi' in kernel space,
but you wouldn't want to use that in userspace.

Looks like armv5 has a bkpt instruction - could that be used?
Or does the kernel need to support armv4?

The last arm I wrote anything for was a strongarm.

	David

-
Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK
Registration No: 1397386 (Wales)


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help