[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20100421153421.GM30306@csn.ul.ie>
Date: Wed, 21 Apr 2010 16:34:21 +0100
From: Mel Gorman <mel@....ul.ie>
To: Christoph Lameter <cl@...ux-foundation.org>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Andrea Arcangeli <aarcange@...hat.com>,
Adam Litke <agl@...ibm.com>, Avi Kivity <avi@...hat.com>,
David Rientjes <rientjes@...gle.com>,
Minchan Kim <minchan.kim@...il.com>,
KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>,
KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>,
Rik van Riel <riel@...hat.com>, linux-kernel@...r.kernel.org,
linux-mm@...ck.org
Subject: Re: [PATCH 04/14] mm,migration: Allow the migration of
PageSwapCache pages
On Wed, Apr 21, 2010 at 10:31:29AM -0500, Christoph Lameter wrote:
> On Wed, 21 Apr 2010, Mel Gorman wrote:
>
> > On Wed, Apr 21, 2010 at 10:05:21AM -0500, Christoph Lameter wrote:
> > > On Wed, 21 Apr 2010, Mel Gorman wrote:
> > >
> > > > No, remap_swapcache could just be called "remap". If it's 0, it's
> > > > considered unsafe to remap the page.
> > >
> > > Call this "can_remap"?
> > >
> >
> > can_do - ba dum tisch.
> >
> > While you are looking though, maybe you can confirm something for me.
> >
> > 1. Is leaving a migration PTE like this behind reasonable? (I think yes
> > particularly as the page was already unmapped so it's not a new fault
> > incurred)
>
> The design of page migration only allows for the existence of these as
> long as the page is locked. Not sure what would happen if you leave this
> hanging around. Paths that are not prepared for a migration_pte may
> encounter one.
>
If there are other paths, then migration of unmapped PageSwapCache is
plain unsafe and this patch would have to go. It'd limit compaction
somewhat but without the series, it would appear that memory hot-remove
is unsafe (albeit almost impossible to trigger).
> > 2. Is the BUG_ON check in
> > include/linux/swapops.h#migration_entry_to_page() now wrong? (I
> > think yes, but I'm not sure and I'm having trouble verifying it)
>
> The bug check ensures that migration entries only occur when the page
> is locked. This patch changes that behavior. This is going too oops
> therefore in unmap_and_move() when you try to remove the migration_ptes
> from an unlocked page.
>
It's not unmap_and_move() that the problem is occurring on but during a
page fault - presumably in do_swap_page but I'm not 100% certain.
--
Mel Gorman
Part-time Phd Student Linux Technology Center
University of Limerick IBM Dublin Software Lab
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists