Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758417AbZJEDJg (ORCPT ); Sun, 4 Oct 2009 23:09:36 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755608AbZJEDJf (ORCPT ); Sun, 4 Oct 2009 23:09:35 -0400 Received: from fgwmail5.fujitsu.co.jp ([192.51.44.35]:44750 "EHLO fgwmail5.fujitsu.co.jp" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754662AbZJEDJf (ORCPT ); Sun, 4 Oct 2009 23:09:35 -0400 X-SecurityPolicyCheck-FJ: OK by FujitsuOutboundMailChecker v1.3.1 Message-ID: <4AC9633B.5030202@jp.fujitsu.com> Date: Mon, 05 Oct 2009 12:08:43 +0900 From: Hidetoshi Seto User-Agent: Thunderbird 2.0.0.23 (Windows/20090812) MIME-Version: 1.0 To: Huang Ying CC: Ingo Molnar , "H. Peter Anvin" , Andi Kleen , "linux-kernel@vger.kernel.org" Subject: [PATCH 5/6] mce-inject: add a barrier to raise_mce() References: <1254100882.15717.1312.camel@yhuang-dev.sh.intel.com> <4AC95F5A.4000708@jp.fujitsu.com> In-Reply-To: <4AC95F5A.4000708@jp.fujitsu.com> Content-Type: text/plain; charset=ISO-2022-JP Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1103 Lines: 32 The prepared mce_inject_cpumask needs to be referred soon in NMI on other CPUs. Reported-by: Huang Ying Signed-off-by: Hidetoshi Seto --- arch/x86/kernel/cpu/mcheck/mce-inject.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/arch/x86/kernel/cpu/mcheck/mce-inject.c b/arch/x86/kernel/cpu/mcheck/mce-inject.c index 105e527..4fb5b78 100644 --- a/arch/x86/kernel/cpu/mcheck/mce-inject.c +++ b/arch/x86/kernel/cpu/mcheck/mce-inject.c @@ -154,6 +154,9 @@ static void raise_mce(struct mce *m) != MCE_INJ_CTX_RANDOM) cpu_clear(cpu, mce_inject_cpumask); } + /* make sure mce_inject_cpumask is visible on other CPUs */ + smp_mb(); + if (!cpus_empty(mce_inject_cpumask)) apic->send_IPI_mask(&mce_inject_cpumask, NMI_VECTOR); start = jiffies; -- 1.6.4.3 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/