Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751212AbVJOTtr (ORCPT ); Sat, 15 Oct 2005 15:49:47 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751213AbVJOTtr (ORCPT ); Sat, 15 Oct 2005 15:49:47 -0400 Received: from 22.107.233.220.exetel.com.au ([220.233.107.22]:34564 "EHLO arnor.apana.org.au") by vger.kernel.org with ESMTP id S1751212AbVJOTtr (ORCPT ); Sat, 15 Oct 2005 15:49:47 -0400 Date: Sun, 16 Oct 2005 05:48:55 +1000 To: Andrea Arcangeli Cc: Nick Piggin , benh@kernel.crashing.org, hugh@veritas.com, paulus@samba.org, anton@samba.org, torvalds@osdl.org, akpm@osdl.org, linux-kernel@vger.kernel.org Subject: Re: Possible memory ordering bug in page reclaim? Message-ID: <20051015194855.GA1164@gondor.apana.org.au> References: <4350C4F6.4030807@yahoo.com.au> <20051015180018.GN18159@opteron.random> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051015180018.GN18159@opteron.random> User-Agent: Mutt/1.5.9i From: Herbert Xu Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 993 Lines: 23 On Sat, Oct 15, 2005 at 06:00:18PM +0000, Andrea Arcangeli wrote: > > Note that the barrier in atomic_add_negative is useless here because it > happens way too late, _after_ the count is decremented (not _before_) > so the decreased count could be already visible to the other cpu. Could you please point me to an architecture that does this? This assumption is in fact made in a number of places in the kernel where constructs such as atomic_add_negative or atomic_dec_and_test are used and assumed to imply a memory barrier. Thanks, -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu ~{PmV>HI~} Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt - 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/