All of lore.kernel.org
 help / color / mirror / Atom feed
From: John Levon <levon@movementarian.org>
To: Mikael Pettersson <mikpe@csd.uu.se>
Cc: linux-kernel@vger.kernel.org,
	oprofile-list@lists.sourceforge.net, torvalds@osdl.org
Subject: Re: [PATCH] allow drivers to claim the lapic NMI watchdog HW
Date: Tue, 4 May 2004 12:02:01 +0100	[thread overview]
Message-ID: <20040504110200.GA9880@compsoc.man.ac.uk> (raw)
In-Reply-To: <200405040233.i442X1GO025270@harpo.it.uu.se>

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?

> -EXPORT_SYMBOL(disable_lapic_nmi_watchdog);
> -EXPORT_SYMBOL(enable_lapic_nmi_watchdog);
> +EXPORT_SYMBOL(reassign_lapic_nmi_watchdog);
> +EXPORT_SYMBOL(release_lapic_nmi_watchdog);

I don't like this new naming. Since the patch is really all about
ownership of the local APIC, can't we call it something like

acquire_lapic_nmi()
release_lapic_nmi()

Neither perfctr nor oprofile have anything to do with watchdogs, so
this:

> -	disable_lapic_nmi_watchdog();
> +	if (reassign_lapic_nmi_watchdog() < 0) {

Looks a little weird now.

regards
john

  reply	other threads:[~2004-05-04 11:02 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 [this message]
2004-05-04 15:57   ` Mikael Pettersson
2004-05-04 13:49     ` Albert Cahalan
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=20040504110200.GA9880@compsoc.man.ac.uk \
    --to=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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.