public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@elte.hu>
To: "Aristeu Rozanski" <aris@redhat.com>,
	"Thomas Gleixner" <tglx@linutronix.de>,
	"H. Peter Anvin" <hpa@zytor.com>,
	"Peter Zijlstra" <a.p.zijlstra@chello.nl>,
	"Frédéric Weisbecker" <fweisbec@gmail.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] x86: introduce NMI_AUTO as nmi_watchdog option
Date: Wed, 4 Nov 2009 12:46:30 +0100	[thread overview]
Message-ID: <20091104114630.GA16993@elte.hu> (raw)
In-Reply-To: <20091103171054.GB25437@redhat.com>


* Aristeu Rozanski <aris@redhat.com> wrote:

> NMI_AUTO is a new nmi_watchdog option that makes LAPIC be tried first 
> and if the CPU isn't supported, IOAPIC will be used. It's useful in 
> cases where NMI watchdog is enabled by default in a kernel built for 
> different machines. It can be configured by default or selected with 
> nmi_watchdog=3 or nmi_watchdog=auto parameters.

What i'd like to see for the NMI watchdog is much more ambitious than 
this: the use of perf events to run a periodic NMI callback.

The NMI watchdog would cause the creation of a per-cpu perf_event 
structure (in-kernel). All x86 CPUs that have perf event support (the 
majority of them) will thus be able to have an NMI watchdog using a 
nice, generic piece of code and we'd be able to phase out the open-coded 
NMI watchdog code.

The user would not notice much from this: we'd still have the 
/proc/sys/kernel/nmi_watchdog toggle to turn it on/off, and we'd still 
have the nmi_watchog= boot parameter as well. But the underlying 
implementation would be far more generic and far more usable than the 
current code.

Would you be interested in moving the NMI watchdog code in this 
direction? Most of the perf events changes (callbacks, helpers for 
in-kernel event allocations, etc.) are in latest -tip already, so you 
could use that as a base.

	Ingo

  reply	other threads:[~2009-11-04 11:46 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-11-03 17:10 [PATCH 2/2] x86: introduce NMI_AUTO as nmi_watchdog option Aristeu Rozanski
2009-11-04 11:46 ` Ingo Molnar [this message]
2009-11-04 12:33   ` Valdis.Kletnieks
2009-11-04 17:42     ` Ingo Molnar
2009-11-04 15:19   ` Aristeu Rozanski
2009-11-04 15:56     ` Ingo Molnar
2009-11-05 10:57       ` Mikael Pettersson
2009-11-08  8:57         ` Ingo Molnar
2009-11-09 20:02       ` Aristeu Rozanski
2009-11-10  5:20         ` Ingo Molnar

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=20091104114630.GA16993@elte.hu \
    --to=mingo@elte.hu \
    --cc=a.p.zijlstra@chello.nl \
    --cc=aris@redhat.com \
    --cc=fweisbec@gmail.com \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tglx@linutronix.de \
    /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