aboutsummaryrefslogtreecommitdiff
path: root/arch/tile/kernel/intvec_32.S
diff options
context:
space:
mode:
authorZhigang Lu <zlu@tilera.com>2014-01-27 16:25:28 +0800
committerChris Metcalf <cmetcalf@tilera.com>2014-03-07 11:19:48 -0500
commitba67823163c963de7f1f2d87526c9c87f3a3ea0b (patch)
tree908c8edc92f82b4565ee0d36003d4b3b2afb0c63 /arch/tile/kernel/intvec_32.S
parent8e3441ebab48c3537b1a9ae06fb7616a3332bd35 (diff)
downloadlinux-stericsson-ba67823163c963de7f1f2d87526c9c87f3a3ea0b.tar.gz
tile: Enable NMIs on return from handle_nmi() without errors
NMI interrupts mask ALL interrupts before calling the handler, so we need to unmask NMIs according to the value handle_nmi() returns. If it returns zero, the NMIs should be re-enabled; if it returns a non-zero error, the NMIs should be disabled. Signed-off-by: Zhigang Lu <zlu@tilera.com> Signed-off-by: Chris Metcalf <cmetcalf@tilera.com>
Diffstat (limited to 'arch/tile/kernel/intvec_32.S')
-rw-r--r--arch/tile/kernel/intvec_32.S11
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/tile/kernel/intvec_32.S b/arch/tile/kernel/intvec_32.S
index 605ffbda44ff..cdbda45a4e4b 100644
--- a/arch/tile/kernel/intvec_32.S
+++ b/arch/tile/kernel/intvec_32.S
@@ -946,6 +946,13 @@ STD_ENTRY(interrupt_return)
bzt r30, .Lrestore_regs
3:
+ /* We are relying on INT_PERF_COUNT at 33, and AUX_PERF_COUNT at 48 */
+ {
+ moveli r0, lo16(1 << (INT_PERF_COUNT - 32))
+ bz r31, .Lrestore_regs
+ }
+ auli r0, r0, ha16(1 << (INT_AUX_PERF_COUNT - 32))
+ mtspr SPR_INTERRUPT_MASK_RESET_K_1, r0
/*
* We now commit to returning from this interrupt, since we will be
@@ -1171,6 +1178,10 @@ handle_nmi:
PTREGS_PTR(r0, PTREGS_OFFSET_BASE)
}
FEEDBACK_REENTER(handle_nmi)
+ {
+ movei r30, 1
+ seq r31, r0, zero
+ }
j interrupt_return
STD_ENDPROC(handle_nmi)