Commit 802c64b3 authored by David S. Miller's avatar David S. Miller

sparc64: On non-Niagara, need to touch NMI watchdog in NOHZ mode.

When we're idling in NOHZ mode, timer interrupts are not running.

Evidence of processing timer interrupts is what the NMI watchdog
uses to determine if the CPU is stuck.

On Niagara, we'll yield the cpu.  This will make the cpu, at
worst, hang out in the hypervisor until an interrupt arrives.
This will prevent the NMI watchdog timer from firing.

However on non-Niagara we just loop executing instructions
which will cause the NMI watchdog to keep firing.  It won't
see timer interrupts happening so it will think the cpu is
stuck.

Fix this by touching the NMI watchdog in the cpu idle loop
on non-Niagara machines.
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent e5553a6d
...@@ -29,6 +29,7 @@ ...@@ -29,6 +29,7 @@
#include <linux/cpu.h> #include <linux/cpu.h>
#include <linux/elfcore.h> #include <linux/elfcore.h>
#include <linux/sysrq.h> #include <linux/sysrq.h>
#include <linux/nmi.h>
#include <asm/uaccess.h> #include <asm/uaccess.h>
#include <asm/system.h> #include <asm/system.h>
...@@ -52,8 +53,10 @@ ...@@ -52,8 +53,10 @@
static void sparc64_yield(int cpu) static void sparc64_yield(int cpu)
{ {
if (tlb_type != hypervisor) if (tlb_type != hypervisor) {
touch_nmi_watchdog();
return; return;
}
clear_thread_flag(TIF_POLLING_NRFLAG); clear_thread_flag(TIF_POLLING_NRFLAG);
smp_mb__after_clear_bit(); smp_mb__after_clear_bit();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment