From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1761329AbZEHJKq (ORCPT ); Fri, 8 May 2009 05:10:46 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1760259AbZEHJKf (ORCPT ); Fri, 8 May 2009 05:10:35 -0400 Received: from mx2.mail.elte.hu ([157.181.151.9]:60833 "EHLO mx2.mail.elte.hu" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756255AbZEHJKe (ORCPT ); Fri, 8 May 2009 05:10:34 -0400 Date: Fri, 8 May 2009 11:10:15 +0200 From: Ingo Molnar To: Andi Kleen Cc: Shaohua Li , lkml , Andrew Morton , Thomas Gleixner , "H. Peter Anvin" , Peter Zijlstra Subject: Re: [PATCH] x86 MCE: shut up lockdep warning Message-ID: <20090508091015.GA2038@elte.hu> References: <1241754429.4444.12.camel@sli10-desk.sh.intel.com> <20090508064517.GX23223@one.firstfloor.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20090508064517.GX23223@one.firstfloor.org> User-Agent: Mutt/1.5.18 (2008-05-17) X-ELTE-VirusStatus: clean X-ELTE-SpamScore: -1.5 X-ELTE-SpamLevel: X-ELTE-SpamCheck: no X-ELTE-SpamVersion: ELTE 2.0 X-ELTE-SpamCheck-Details: score=-1.5 required=5.9 tests=BAYES_00 autolearn=no SpamAssassin version=3.2.3 -1.5 BAYES_00 BODY: Bayesian spam probability is 0 to 1% [score: 0.0000] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Andi Kleen wrote: > On Fri, May 08, 2009 at 11:47:09AM +0800, Shaohua Li wrote: > > lockdep report below warning when I try to offline one cpu: > > [ 110.835487] ================================= > > [ 110.835616] [ INFO: inconsistent lock state ] > > [ 110.835688] 2.6.30-rc4-00336-g8c9ed89 #52 > > [ 110.835757] --------------------------------- > > [ 110.835828] inconsistent {HARDIRQ-ON-W} -> {IN-HARDIRQ-W} usage. > > [ 110.835908] swapper/0 [HC1[1]:SC0[0]:HE0:SE1] takes: > > [ 110.835982] (cmci_discover_lock){?.+...}, at: [] cmci_clear+0x30/0x9b > > > > smp_call_function_single() will disable interrupt. moving mce reenable/disable > > to workqueue, so no irq is disabled. > > Looks good. Thanks. > > Acked-by: Andi Kleen The report is useful, but the fix does not look good at all, and you should never have acked it: - it works around a lockdep warning - you did not realize the real bug while the warning was plain - plus the patch introduces a fragile (because complex) work_on_cpu() call into the CPU hotplug path, which could have caused followup regressions. Please also Cc: the relevant upstream subsystem maintainers in such cases (the x86 maintaiers in this case). Thanks, Ingo