]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
powerpc/64s: masked_interrupt() returns to kernel so avoid restoring r13
authorNicholas Piggin <npiggin@gmail.com>
Fri, 11 Aug 2017 16:39:01 +0000 (02:39 +1000)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 23 Aug 2017 13:11:28 +0000 (23:11 +1000)
Places in the kernel where r13 is not the PACA pointer must have
maskable interrupts disabled, so r13 does not have to be restored when
returning from a soft-masked interrupt. We should never have
interrupts soft disabled when we're in user space.

Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/kernel/exceptions-64s.S

index 2cc5e9d4c907e963465d3c6cafb4f048f624d748..6a6d4d9208272733432cf8a9e873770ac8ff76ed 100644 (file)
@@ -1379,7 +1379,7 @@ masked_##_H##interrupt:                                   \
        ld      r9,PACA_EXGEN+EX_R9(r13);               \
        ld      r10,PACA_EXGEN+EX_R10(r13);             \
        ld      r11,PACA_EXGEN+EX_R11(r13);             \
-       GET_SCRATCH0(r13);                              \
+       /* returns to kernel where r13 must be set up, so don't restore it */ \
        ##_H##rfid;                                     \
        b       .;                                      \
        MASKED_DEC_HANDLER(_H)