Skip to content
Commit 6ef83ab6 authored by Sean Anderson's avatar Sean Anderson Committed by Tom Rini
Browse files

arm: semihosting: Fix returning from traps on ARMv6 and lower



U-Boot runs in supervisor mode. On ARMv6 and lower, software interrupts
are taken in supervisor mode. When entering an interrupt, the link
register is set to the address of the next instruction. However, if we
are already in supervisor mode, this clobbers the link register. The
debugger can't help us, since by the time it notices we've taken a
software interrupt, the link register is already gone. Work around this
by moving the return address to another register.

Signed-off-by: default avatarSean Anderson <sean.anderson@seco.com>
parent 298c26c5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment