aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/watchdog/hpwdt.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2008-06-16 05:27:53 -0400
committerIngo Molnar <mingo@elte.hu>2008-06-16 05:27:53 -0400
commitc54f9da1c8ceee19436430afac0798a989eb886d (patch)
tree412f51c3f2641e4205b767cec95ce6107cd39d36 /drivers/watchdog/hpwdt.c
parenta2eddfa95919a730e0e5ed17e9c303fe5ba249cd (diff)
parent066519068ad2fbe98c7f45552b1f592903a9c8c8 (diff)
Merge branch 'linus' into x86/irqstats
Diffstat (limited to 'drivers/watchdog/hpwdt.c')
-rw-r--r--drivers/watchdog/hpwdt.c27
1 files changed, 12 insertions, 15 deletions
diff --git a/drivers/watchdog/hpwdt.c b/drivers/watchdog/hpwdt.c
index 6483d1066b95..6a63535fc04d 100644
--- a/drivers/watchdog/hpwdt.c
+++ b/drivers/watchdog/hpwdt.c
@@ -418,23 +418,20 @@ static int hpwdt_pretimeout(struct notifier_block *nb, unsigned long ulReason,
418 static unsigned long rom_pl; 418 static unsigned long rom_pl;
419 static int die_nmi_called; 419 static int die_nmi_called;
420 420
421 if (ulReason != DIE_NMI && ulReason != DIE_NMI_IPI) 421 if (ulReason == DIE_NMI || ulReason == DIE_NMI_IPI) {
422 return NOTIFY_OK; 422 spin_lock_irqsave(&rom_lock, rom_pl);
423 423 if (!die_nmi_called)
424 spin_lock_irqsave(&rom_lock, rom_pl); 424 asminline_call(&cmn_regs, cru_rom_addr);
425 if (!die_nmi_called) 425 die_nmi_called = 1;
426 asminline_call(&cmn_regs, cru_rom_addr); 426 spin_unlock_irqrestore(&rom_lock, rom_pl);
427 die_nmi_called = 1; 427 if (cmn_regs.u1.ral != 0) {
428 spin_unlock_irqrestore(&rom_lock, rom_pl); 428 panic("An NMI occurred, please see the Integrated "
429 if (cmn_regs.u1.ral == 0) { 429 "Management Log for details.\n");
430 printk(KERN_WARNING "hpwdt: An NMI occurred, " 430 }
431 "but unable to determine source.\n");
432 } else {
433 panic("An NMI occurred, please see the Integrated "
434 "Management Log for details.\n");
435 } 431 }
436 432
437 return NOTIFY_STOP; 433 die_nmi_called = 0;
434 return NOTIFY_DONE;
438} 435}
439 436
440/* 437/*