Linux MIPS Architecture development
 help / color / mirror / Atom feed
* [PATCH] MIPS: add nmi_enter() + nmi_exit() to nmi_exception_handler()
@ 2015-10-19 18:49 Petri Gynther
  2015-11-02 20:50 ` Petri Gynther
  0 siblings, 1 reply; 6+ messages in thread
From: Petri Gynther @ 2015-10-19 18:49 UTC (permalink / raw)
  To: linux-mips; +Cc: ralf, Petri Gynther

We need to enter NMI context when NMI interrupt fires.

Signed-off-by: Petri Gynther <pgynther@google.com>
---
 arch/mips/kernel/traps.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/mips/kernel/traps.c b/arch/mips/kernel/traps.c
index fdb392b..efcedd4 100644
--- a/arch/mips/kernel/traps.c
+++ b/arch/mips/kernel/traps.c
@@ -1856,12 +1856,14 @@ void __noreturn nmi_exception_handler(struct pt_regs *regs)
 {
 	char str[100];
 
+	nmi_enter();
 	raw_notifier_call_chain(&nmi_chain, 0, regs);
 	bust_spinlocks(1);
 	snprintf(str, 100, "CPU%d NMI taken, CP0_EPC=%lx\n",
 		 smp_processor_id(), regs->cp0_epc);
 	regs->cp0_epc = read_c0_errorepc();
 	die(str, regs);
+	nmi_exit();
 }
 
 #define VECTORSPACING 0x100	/* for EI/VI mode */
-- 
2.6.0.rc2.230.g3dd15c0

^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2016-01-12 21:38 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-19 18:49 [PATCH] MIPS: add nmi_enter() + nmi_exit() to nmi_exception_handler() Petri Gynther
2015-11-02 20:50 ` Petri Gynther
2015-11-09  8:09   ` Ralf Baechle
2016-01-12  1:03     ` Maciej W. Rozycki
2016-01-12 13:50       ` Ralf Baechle
2016-01-12 21:38         ` Maciej W. Rozycki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox