From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Tue, 13 Aug 2002 13:41:42 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Tue, 13 Aug 2002 13:40:50 -0400 Received: from parcelfarce.linux.theplanet.co.uk ([195.92.249.252]:7691 "EHLO www.linux.org.uk") by vger.kernel.org with ESMTP id ; Tue, 13 Aug 2002 13:39:59 -0400 Message-ID: <3D5947B7.EDE01C2E@zip.com.au> Date: Tue, 13 Aug 2002 10:53:59 -0700 From: Andrew Morton X-Mailer: Mozilla 4.79 [en] (X11; U; Linux 2.4.19-rc5 i686) X-Accept-Language: en MIME-Version: 1.0 To: Linus Torvalds CC: lkml , "David S. Miller" Subject: Re: [patch 2/21] reduced locking in buffer.c References: <3D561473.40A53C0D@zip.com.au> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Linus Torvalds wrote: > > On Sun, 11 Aug 2002, Andrew Morton wrote: > > > > Resend. Replace the buffer lru spinlock protection with > > local_irq_disable and a cross-CPU call to invalidate them. > > This almost certainly breaks on sparc, where CPU cross-calls are > non-maskable, so local_irq_disable doesn't do anything for them. > > Talk to Davem about this - there may be some workaround. I have discussed it with David - he said it's OK in 2.5, but not in 2.4, and he has eyeballed the diff. However there's another thing to think about: local_irq_disable(); atomic_inc(); If the architecture implements atomic_inc with spinlocks, this will schedule with interrupts off with CONFIG_PREEMPT=y, I expect. I can fix that with a preempt_disable() in there, but ick.