From: Michal Hocko <mhocko@kernel.org>
To: "Liang, Kan" <kan.liang@intel.com>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"dzickus@redhat.com" <dzickus@redhat.com>,
"mingo@kernel.org" <mingo@kernel.org>,
"akpm@linux-foundation.org" <akpm@linux-foundation.org>,
"babu.moger@oracle.com" <babu.moger@oracle.com>,
"atomlin@redhat.com" <atomlin@redhat.com>,
"prarit@redhat.com" <prarit@redhat.com>,
"torvalds@linux-foundation.org" <torvalds@linux-foundation.org>,
"peterz@infradead.org" <peterz@infradead.org>,
"tglx@linutronix.de" <tglx@linutronix.de>,
"eranian@google.com" <eranian@google.com>,
"acme@redhat.com" <acme@redhat.com>,
"ak@linux.intel.com" <ak@linux.intel.com>,
"stable@vger.kernel.org" <stable@vger.kernel.org>
Subject: Re: [PATCH] kernel/watchdog: fix spurious hard lockups
Date: Wed, 28 Jun 2017 16:29:52 +0200 [thread overview]
Message-ID: <20170628142952.GI5225@dhcp22.suse.cz> (raw)
In-Reply-To: <37D7C6CF3E00A74B8858931C1DB2F07753713A22@SHSMSX103.ccr.corp.intel.com>
On Wed 28-06-17 13:24:08, Liang, Kan wrote:
>
> > > From: Kan Liang <Kan.liang@intel.com>
> > >
> > > Some users reported spurious NMI watchdog timeouts.
> > >
> > > We now have more and more systems where the Turbo range is wide
> > enough
> > > that the NMI watchdog expires faster than the soft watchdog timer that
> > > updates the interrupt tick the NMI watchdog relies on.
> >
> > AFAIR the watchdog doesn't rely on deferred timers so this would suggest
> > that a standard hrtimer can expire much later than programmed, right?
>
> The softlockup watchdog relies on hrtimers.
> The hardlockup watchdog (NMI watchdog) relies on perf subsystem and
> using unhalted CPU cycles.
> When the softlockup watchdog expires, it updates the hrtimer_interrupts.
> When the NMI watchdog expires, it will check the hrtimer_interrupts, and
> determine if it's a hardlockup.
> The design was to make the softlockup watchdog runs with 2.5 times the
> rate of NMI watchdog. So it guarantees that the hrtimer_interrupts is
> updated before the NMI watchdog expires.
> That works well if Turbo-Mode is disabled.
> However, when Turbo-Mode is enabled, unhalted CPU cycles might run
> much faster than expected, even faster than softlockup watchdog.
> So the softlockup watchdog will not get a chance to update the
> hrtimer_interrupts, which will trigger false positives.
So it is not the hrtimer which doesn't fire but rather the NMI events
fire too quickly, right?
--
Michal Hocko
SUSE Labs
next prev parent reply other threads:[~2017-06-28 14:29 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-20 21:33 [PATCH] kernel/watchdog: fix spurious hard lockups kan.liang
2017-06-20 22:03 ` Andrew Morton
2017-06-21 12:40 ` Liang, Kan
2017-06-21 13:47 ` Don Zickus
2017-06-21 14:10 ` Liang, Kan
2017-06-20 22:34 ` Prarit Bhargava
2017-06-20 23:00 ` Andi Kleen
2017-06-21 0:12 ` Prarit Bhargava
2017-06-21 21:02 ` Marc Herbert
2017-06-21 13:40 ` Don Zickus
2017-06-21 14:02 ` Liang, Kan
2017-06-28 11:40 ` Michal Hocko
2017-06-28 13:24 ` Liang, Kan
2017-06-28 14:29 ` Michal Hocko [this message]
2017-06-28 14:32 ` Liang, Kan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170628142952.GI5225@dhcp22.suse.cz \
--to=mhocko@kernel.org \
--cc=acme@redhat.com \
--cc=ak@linux.intel.com \
--cc=akpm@linux-foundation.org \
--cc=atomlin@redhat.com \
--cc=babu.moger@oracle.com \
--cc=dzickus@redhat.com \
--cc=eranian@google.com \
--cc=kan.liang@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=peterz@infradead.org \
--cc=prarit@redhat.com \
--cc=stable@vger.kernel.org \
--cc=tglx@linutronix.de \
--cc=torvalds@linux-foundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox