Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756974AbZDTV6q (ORCPT ); Mon, 20 Apr 2009 17:58:46 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755980AbZDTV6d (ORCPT ); Mon, 20 Apr 2009 17:58:33 -0400 Received: from e3.ny.us.ibm.com ([32.97.182.143]:48637 "EHLO e3.ny.us.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755548AbZDTV6c (ORCPT ); Mon, 20 Apr 2009 17:58:32 -0400 Date: Mon, 20 Apr 2009 14:58:27 -0700 From: "Paul E. McKenney" To: Paul Mackerras Cc: Eric Dumazet , Stephen Hemminger , Evgeniy Polyakov , David Miller , kaber@trash.net, torvalds@linux-foundation.org, jeff.chua.linux@gmail.com, mingo@elte.hu, laijs@cn.fujitsu.com, jengelh@medozas.de, r000n@r000n.net, linux-kernel@vger.kernel.org, netfilter-devel@vger.kernel.org, netdev@vger.kernel.org, benh@kernel.crashing.org, mathieu.desnoyers@polymtl.ca Subject: Re: [PATCH] netfilter: use per-cpu recursive lock (v10) Message-ID: <20090420215827.GK6822@linux.vnet.ibm.com> Reply-To: paulmck@linux.vnet.ibm.com References: <49E72E83.50702@trash.net> <20090416.153354.170676392.davem@davemloft.net> <20090416234955.GL6924@linux.vnet.ibm.com> <20090417012812.GA25534@linux.vnet.ibm.com> <20090418094001.GA2369@ioremap.net> <20090418141455.GA7082@linux.vnet.ibm.com> <20090420103414.1b4c490f@nehalam> <49ECBE0A.7010303@cosmosbay.com> <18924.59347.375292.102385@cargo.ozlabs.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <18924.59347.375292.102385@cargo.ozlabs.ibm.com> User-Agent: Mutt/1.5.15+20070412 (2007-04-11) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 719 Lines: 18 On Tue, Apr 21, 2009 at 07:23:31AM +1000, Paul Mackerras wrote: > Eric Dumazet writes: > > > OK, but we still have a problem on machines with >= 250 cpus, > > because calling 250 times spin_lock() is going to overflow preempt_count, > > as each spin_lock() increases preempt_count by one. > > Huh? Each cpu has its own separate preempt_count. But a single CPU is acquiring one lock per CPU, so all the increments are to one CPU's preempt_count. :-( Thanx, Paul -- 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/