From: Albert Cahalan <albert@users.sf.net>
To: Mikael Pettersson <mikpe@csd.uu.se>
Cc: John Levon <levon@movementarian.org>,
linux-kernel mailing list <linux-kernel@vger.kernel.org>,
oprofile-list@lists.sourceforge.net,
Linus Torvalds <torvalds@osdl.org>
Subject: Re: [PATCH] allow drivers to claim the lapic NMI watchdog HW
Date: 04 May 2004 09:49:02 -0400 [thread overview]
Message-ID: <1083678542.951.158.camel@cube> (raw)
In-Reply-To: <16535.48497.41972.583857@alkaid.it.uu.se>
On Tue, 2004-05-04 at 11:57, Mikael Pettersson wrote:
> John Levon writes:
> > On Tue, May 04, 2004 at 04:33:01AM +0200, Mikael Pettersson wrote:
> >
> > > +/* lapic_nmi_owner:
> > > + * +1: the lapic NMI hardware is assigned to the lapic NMI watchdog
> > > + * 0: the lapic NMI hardware is unassigned
> >
> > If we're going to have a mini state machine, can't we at least use some
> > defines for each state...
> >
> > > + lapic_nmi_owner -= 2; /* +1 -> -1, 0 -> -2 */
> >
> > ...and make this into some readable english via a little helper?
>
> Thing is, using discrete states makes the code for the checks
> and state changes more verbose. However, I can easily hide the
> representation behind macros with understandable names.
It looked like 2 flag bits to me.
#define LAPIC_WATCHDOG_WANTS_NMI 0x00000001
#define LAPIC_OTHER_DRIVER_HAS_NMI 0x00000002
next prev parent reply other threads:[~2004-05-04 16:12 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-05-04 2:33 [PATCH] allow drivers to claim the lapic NMI watchdog HW Mikael Pettersson
2004-05-04 11:02 ` John Levon
2004-05-04 15:57 ` Mikael Pettersson
2004-05-04 13:49 ` Albert Cahalan [this message]
2004-05-05 9:19 ` [PATCH][updated] " Mikael Pettersson
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=1083678542.951.158.camel@cube \
--to=albert@users.sf.net \
--cc=levon@movementarian.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mikpe@csd.uu.se \
--cc=oprofile-list@lists.sourceforge.net \
--cc=torvalds@osdl.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