mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andi Kleen <andi@firstfloor.org>
To: greg@kroah.com, linux-kernel@vger.kernel.org
Subject: [PATCH] [3/4] Convert the x86 mce tolerant sysdev attribute to generic attribute
Date: Tue,  1 Jul 2008 18:48:43 +0200 (CEST)	[thread overview]
Message-ID: <20080701164843.EA94A1B4314@basil.firstfloor.org> (raw)
In-Reply-To: <20080701648.901668603@firstfloor.org>


Use the new generic int attribute accessors for the x86 mce tolerant
attribute. Simple example to illustrate the new macros. 

There are much more places all over the tree that could be converted
like this.

Signed-off-by: Andi Kleen <ak@linux.intel.com>

Index: linux/arch/x86/kernel/cpu/mcheck/mce_64.c
===================================================================
--- linux.orig/arch/x86/kernel/cpu/mcheck/mce_64.c
+++ linux/arch/x86/kernel/cpu/mcheck/mce_64.c
@@ -785,12 +785,12 @@ static ssize_t set_trigger(struct sys_de
 }
 
 static SYSDEV_ATTR(trigger, 0644, show_trigger, set_trigger);
-ACCESSOR(tolerant,tolerant,)
+static SYSDEV_INT_ATTR(tolerant, 0644, tolerant);
 ACCESSOR(check_interval,check_interval,mce_restart())
 static struct sysdev_attribute *mce_attributes[] = {
 	&attr_bank0ctl, &attr_bank1ctl, &attr_bank2ctl,
 	&attr_bank3ctl, &attr_bank4ctl, &attr_bank5ctl,
-	&attr_tolerant, &attr_check_interval, &attr_trigger,
+	&attr_tolerant.attr, &attr_check_interval, &attr_trigger,
 	NULL
 };
 

  parent reply	other threads:[~2008-07-01 16:49 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-01 16:48 [PATCH] [1/4] Pass the attribute to the low level sysdev show/store function Andi Kleen
2008-07-01 16:48 ` [PATCH] [2/4] Add utility functions for simple int/ulong variable sysdev attributes Andi Kleen
2008-07-01 16:48 ` Andi Kleen [this message]
2008-07-01 16:48 ` [PATCH] [4/4] Implement dynamic machine check banks support Andi Kleen

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=20080701164843.EA94A1B4314@basil.firstfloor.org \
    --to=andi@firstfloor.org \
    --cc=greg@kroah.com \
    --cc=linux-kernel@vger.kernel.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

Powered by JetHome