]> www.infradead.org Git - users/jedix/linux-maple.git/commit
xtensa: fix kernel register spilling
authorMax Filippov <jcmvbkbc@gmail.com>
Thu, 16 Jul 2015 07:41:02 +0000 (10:41 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 21 Sep 2015 17:05:42 +0000 (10:05 -0700)
commit3799248733cbdb14ca12b0680a2e776cb35e19fe
tree2982045aaf2f7f341852856f533d623d83883903
parent36c2895c6b132f8ff19074f6d226bcedf2614e89
xtensa: fix kernel register spilling

commit 77d6273e79e3a86552fcf10cdd31a69b46ed2ce6 upstream.

call12 can't be safely used as the first call in the inline function,
because the compiler does not extend the stack frame of the bounding
function accordingly, which may result in corruption of local variables.

If a call needs to be done, do call8 first followed by call12.

For pure assembly code in _switch_to increase stack frame size of the
bounding function.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/xtensa/include/asm/traps.h
arch/xtensa/kernel/entry.S