From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753518Ab1L1KZp (ORCPT ); Wed, 28 Dec 2011 05:25:45 -0500 Received: from gate.crashing.org ([63.228.1.57]:43739 "EHLO gate.crashing.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753307Ab1L1KZn (ORCPT ); Wed, 28 Dec 2011 05:25:43 -0500 Message-ID: <1325067910.6632.42.camel@pasglop> Subject: Re: [GIT PULL] slab fixes for 3.2-rc4 From: Benjamin Herrenschmidt To: Linus Torvalds Cc: Tejun Heo , Christoph Lameter , Pekka Enberg , Ingo Molnar , Andrew Morton , linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, Thomas Gleixner Date: Wed, 28 Dec 2011 21:25:10 +1100 In-Reply-To: References: <20111220162315.GC10752@google.com> <20111220202854.GH10752@google.com> <20111221170535.GB9213@google.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.2.2- Content-Transfer-Encoding: 7bit Mime-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2011-12-21 at 18:19 -0800, Linus Torvalds wrote: > On Wed, Dec 21, 2011 at 9:05 AM, Tejun Heo wrote: > > > > machines. (cc'ing arch) Does anyone have better insight here? How > > much more expensive are local irq save/restore compared to inc/dec'ing > > preempt count on various archs? > > I think powerpc does sw irq disable, so it's pretty much the same. On 64-bit only, but it's probably still better than going for an atomic op, our atomics tend to be handled at the l2 level and so are sloooow. .../... > So I really suspect that we could just say: "make the irq-safe version > be the *only* version", and no architecture will really care. Sure, it > can be more expensive, but it usually isn't. Only when done badly and > stupidly is it nasty. Agreed, keep it simple, or we'll just grow more bugs like this one. Cheers, Ben.