powerpc/irq: Use current_stack_pointer in check_stack_overflow()
authorChristophe Leroy <christophe.leroy@c-s.fr>
Thu, 20 Feb 2020 11:51:39 +0000 (22:51 +1100)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 4 Mar 2020 11:44:28 +0000 (22:44 +1100)
commit84ab14893054751a2b3adba725834183b872a17f
tree300bae86cf5ed6feb2813b92b034ae8313af8938
parent0e63f0151719ee4cb90d85e60c98045099c995e2
powerpc/irq: Use current_stack_pointer in check_stack_overflow()

The purpose of check_stack_overflow() is to verify that the stack has
not overflowed.

To really know whether the stack pointer is still within boundaries,
the check must be done directly on the value of r1.

So use current_stack_pointer, which returns the current value of r1,
rather than current_stack_frame() which causes a frame to be created
and then returns that value.

Signed-off-by: Christophe Leroy <christophe.leroy@c-s.fr>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20200220115141.2707-3-mpe@ellerman.id.au
arch/powerpc/kernel/irq.c