From mboxrd@z Thu Jan 1 00:00:00 1970 Date: Mon, 20 Oct 2008 04:26:39 +0100 (BST) From: Hugh Dickins Subject: Re: [patch] mm: fix anon_vma races In-Reply-To: Message-ID: References: <20081016041033.GB10371@wotan.suse.de> <1224285222.10548.22.camel@lappy.programming.kicks-ass.net> <20081018013258.GA3595@wotan.suse.de> <20081018022541.GA19018@wotan.suse.de> <20081019030325.GE16562@wotan.suse.de> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-linux-mm@kvack.org Return-Path: To: Nick Piggin Cc: Linus Torvalds , Peter Zijlstra , Linux Memory Management List List-ID: On Sun, 19 Oct 2008, Hugh Dickins wrote: > On Sun, 19 Oct 2008, Nick Piggin wrote: > > > > There is already a page_mapped check in there. I'm just going to > > propose we move that down. No extra branchesin the fastpath. OK? > > That should be OK, yes. Looking back at the history, I believe > I sited the page_mapped test where it is, partly for simpler flow, > and partly to avoid overhead of taking spinlock unnecessarily. Arrgh! What terrible advice I gave you there, completely wrong: that's what happens when I rush a reply instead of thinking. I'm three-quarters through replying to Linus on this, and going into that detail, remember now why its placement is critical. Repeat the page_mapped check before returning if you wish, but do not remove the one that's there: see other mail for explanation. Hugh -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org