powerpc/tm: do not use r13 for tabort_syscall
authorNicholas Piggin <npiggin@gmail.com>
Mon, 25 Jul 2016 04:26:51 +0000 (14:26 +1000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 24 Sep 2016 08:07:35 +0000 (10:07 +0200)
commit53545131ecea3a41f4b1b4f6d8b04c8a2a78ac35
tree1d3ac5c108d56824666bdeac37fe97ce8ea2c3bc
parente70bb22b8fc502757332d06a484696ce3efa9d2a
powerpc/tm: do not use r13 for tabort_syscall

commit cc7786d3ee7e3c979799db834b528db2c0834c2e upstream.

tabort_syscall runs with RI=1, so a nested recoverable machine
check will load the paca into r13 and overwrite what we loaded
it with, because exceptions returning to privileged mode do not
restore r13.

Fixes: b4b56f9ecab4 (powerpc/tm: Abort syscalls in active transactions)
Signed-off-by: Nick Piggin <npiggin@gmail.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/powerpc/kernel/entry_64.S