public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Hidetoshi Seto <seto.hidetoshi@jp.fujitsu.com>
To: Mauro Carvalho Chehab <mchehab@redhat.com>
Cc: bluesmoke-devel@lists.sourceforge.net,
	linux-kernel@vger.kernel.org, Ingo Molnar <mingo@elte.hu>,
	Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [PATCH 00/63] i7core_edac and edac_mce
Date: Fri, 25 Sep 2009 11:48:39 +0900	[thread overview]
Message-ID: <4ABC2F87.7070001@jp.fujitsu.com> (raw)
In-Reply-To: <20090924192821.7fcffc80@pedra.chehab.org>

Mauro Carvalho Chehab wrote:
> The content of this patch series is at:
> 	git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/i7core.git for_linus
> 
> The first submission were done on Sept, 5 but weren't reviewed until 
> yesterday. 
> 
> It is not yet a pull request. It is just the last version, after the 
> last review.
> 
> My intention is to submit likely tomorrow a git pull request if 
> everything is ok and hoping that Linus will still accept it for 2.6.32.
> 
> This time I'm sending the it as a patch series for better review. The complete
> patchset is being sent to EDAC ML (bluesmoke-devel@lists.sourceforge.net).
> 
> Only this email and two others of this series is c/c at LKML. If more people is
> interested on reviewing it, you can always look at -git and/or bluesmoke archives.
> 
> The two patches c/c at LKML are:
> - the one that touches at PCI, for probing buses 254 and 255 - since, by
>   default, ACPI bios doesn't announce those buses with MCU registers;
> - edac_mce glue driver, that add two hooks on mce that are called only if a
>   driver is registered for receiving mce log events. This is needed in order to
>   get corrected error reports at the EDAC driver.
> 
> Cheers,
> Mauro

Interesting, but yes, definitely it needs more reviews.

Thanks,
H.Seto


Subject: [UNTESTED PATCH] i7core_edac: avoid spinlock on fatal error

Be careful on MCE context, or it might cause a deadlock.

Signed-off-by: Hidetoshi Seto <seto.hidetoshi@jp.fujitsu.com>
---
 drivers/edac/i7core_edac.c |   10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/drivers/edac/i7core_edac.c b/drivers/edac/i7core_edac.c
index 97f6d17..f915a39 100644
--- a/drivers/edac/i7core_edac.c
+++ b/drivers/edac/i7core_edac.c
@@ -1679,6 +1679,12 @@ static int i7core_mce_check_error(void *priv, struct mce *mce)
 		return 0;
 	}
 
+	/* Handle fatal errors immediately */
+	if (mce->mcgstatus & 1) {
+		i7core_mce_output_error(mci, mce);
+		return 1;
+	}
+
 	spin_lock_irqsave(&pvt->mce_lock, flags);
 	if (pvt->mce_count < MCE_LOG_LEN) {
 		memcpy(&pvt->mce_entry[pvt->mce_count], mce, sizeof(*mce));
@@ -1686,10 +1692,6 @@ static int i7core_mce_check_error(void *priv, struct mce *mce)
 	}
 	spin_unlock_irqrestore(&pvt->mce_lock, flags);
 
-	/* Handle fatal errors immediately */
-	if (mce->mcgstatus & 1)
-		i7core_check_error(mci);
-
 	/* Advice mcelog that the error were handled */
 	return 1;
 }
-- 
1.6.4.3


  reply	other threads:[~2009-09-25  2:49 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-24 22:28 [PATCH 00/63] i7core_edac and edac_mce Mauro Carvalho Chehab
2009-09-25  2:48 ` Hidetoshi Seto [this message]
2009-10-04 19:16 ` [PATCH 0/3] " Mauro Carvalho Chehab
2009-10-04 19:43 ` [PATCH 3/3] i7core_edac: Better parse "any" addrmask Mauro Carvalho Chehab
2009-10-04 19:43 ` [PATCH 2/3] i7core_edac: Use a lockless ringbuffer Mauro Carvalho Chehab
2009-10-04 19:43 ` [PATCH 1/3] edac: Create an unique instance for each kobj Mauro Carvalho Chehab
2009-10-14  3:01   ` Andrew Morton
2009-10-14  9:41     ` Mauro Carvalho Chehab
2009-10-14 14:50       ` Colbert, Rusty
2009-10-14 15:21         ` Mauro Carvalho Chehab

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=4ABC2F87.7070001@jp.fujitsu.com \
    --to=seto.hidetoshi@jp.fujitsu.com \
    --cc=akpm@linux-foundation.org \
    --cc=bluesmoke-devel@lists.sourceforge.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mchehab@redhat.com \
    --cc=mingo@elte.hu \
    /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