From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail203.messagelabs.com (mail203.messagelabs.com [216.82.254.243]) by kanga.kvack.org (Postfix) with SMTP id CBD446B00CF for ; Sun, 14 Mar 2010 11:01:25 -0400 (EDT) Received: by pzk30 with SMTP id 30so595507pzk.12 for ; Sun, 14 Mar 2010 08:01:24 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <1268412087-13536-2-git-send-email-mel@csn.ul.ie> References: <1268412087-13536-1-git-send-email-mel@csn.ul.ie> <1268412087-13536-2-git-send-email-mel@csn.ul.ie> Date: Mon, 15 Mar 2010 00:01:24 +0900 Message-ID: <28c262361003140801m44083ad7o784f878d58085948@mail.gmail.com> Subject: Re: [PATCH 01/11] mm,migration: Take a reference to the anon_vma before migrating From: Minchan Kim Content-Type: text/plain; charset=UTF-8 Sender: owner-linux-mm@kvack.org To: Mel Gorman Cc: Andrew Morton , Andrea Arcangeli , Christoph Lameter , Adam Litke , Avi Kivity , David Rientjes , KOSAKI Motohiro , Rik van Riel , linux-kernel@vger.kernel.org, linux-mm@kvack.org List-ID: On Sat, Mar 13, 2010 at 1:41 AM, Mel Gorman wrote: > rmap_walk_anon() does not use page_lock_anon_vma() for looking up and > locking an anon_vma and it does not appear to have sufficient locking to > ensure the anon_vma does not disappear from under it. > > This patch copies an approach used by KSM to take a reference on the > anon_vma while pages are being migrated. This should prevent rmap_walk() > running into nasty surprises later because anon_vma has been freed. > > Signed-off-by: Mel Gorman > Acked-by: Rik van Riel Reviewed-by: Minchan Kim BTW, This another refcount of anon_vma is merged with KSM by [3/11]. Looks good to me. -- Kind regards, Minchan Kim -- 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