]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/64s: Fix stack setup in watchdog soft_nmi_common()
authorNicholas Piggin <npiggin@gmail.com>
Sat, 29 Jul 2017 12:50:27 +0000 (22:50 +1000)
committerMichael Ellerman <mpe@ellerman.id.au>
Mon, 31 Jul 2017 10:22:37 +0000 (20:22 +1000)
commit15807663fb553757f9f83ba04c8e3ffcf0736ae5
tree5b2d43d7d4bf922f96f9eb5dd7485131360c4231
parentc40fea0c84a9d8e40edb3951477b87a13718af3e
powerpc/64s: Fix stack setup in watchdog soft_nmi_common()

The watchdog soft-NMI exception stack setup loads a stack pointer
twice, which is an obvious error. It ends up using the system reset
interrupt (true-NMI) stack, which is also a bug because the watchdog
could be preempted by a system reset interrupt that overwrites the
NMI stack.

Change the soft-NMI to use the "emergency stack". The current kernel
stack is not used, because of the longer-term goal to prevent
asynchronous stack access using soft-disable.

Fixes: 3ac087868b4c ("powerpc/64s: implement arch-specific hardlockup watchdog")
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/kernel/exceptions-64s.S