ARM: 8671/1: V7M: Preserve registers across switch from Thread to Handler mode
authorVladimir Murzin <vladimir.murzin@arm.com>
Mon, 24 Apr 2017 09:41:53 +0000 (10:41 +0100)
committerRussell King <rmk+kernel@armlinux.org.uk>
Wed, 26 Apr 2017 09:59:36 +0000 (10:59 +0100)
commitb70cd406d7fe9976962d621d8c60d324eb47d284
tree98aa98df6b8f749605d72cc6f74ace87d830152b
parent6f05d0761af612e04572ba4d65b4c0274a88444f
ARM: 8671/1: V7M: Preserve registers across switch from Thread to Handler mode

According to ARMv7 ARM, when exception is taken content of r0-r3, r12
is unknown (see ExceptionTaken() pseudocode). Even though existent
implementations keep these register unchanged, preserve them to be in
line with architecture.

Reported-by: Dobromir Stefanov <dobromir.stefanov@arm.com>
Signed-off-by: Vladimir Murzin <vladimir.murzin@arm.com>
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
arch/arm/mm/proc-v7m.S