[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Pine.LNX.4.64.0909081227010.25652@sister.anvils>
Date: Tue, 8 Sep 2009 12:30:39 +0100 (BST)
From: Hugh Dickins <hugh.dickins@...cali.co.uk>
To: KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>
cc: Andrew Morton <akpm@...ux-foundation.org>,
Hiroaki Wakabayashi <primulaelatior@...il.com>,
Lee Schermerhorn <lee.schermerhorn@...com>,
KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>,
Linus Torvalds <torvalds@...ux-foundation.org>,
Nick Piggin <npiggin@...e.de>, Rik van Riel <riel@...hat.com>,
linux-kernel@...r.kernel.org, linux-mm@...ck.org
Subject: Re: [PATCH 1/8] mm: munlock use follow_page
On Tue, 8 Sep 2009, KAMEZAWA Hiroyuki wrote:
> On Mon, 7 Sep 2009 22:29:55 +0100 (BST)
> Hugh Dickins <hugh.dickins@...cali.co.uk> wrote:
> > void munlock_vma_pages_range(struct vm_area_struct *vma,
> > - unsigned long start, unsigned long end)
> > + unsigned long start, unsigned long end)
> > {
> > + unsigned long addr;
> > +
> > + lru_add_drain();
> > vma->vm_flags &= ~VM_LOCKED;
> > - __mlock_vma_pages_range(vma, start, end, 0);
> > +
> > + for (addr = start; addr < end; addr += PAGE_SIZE) {
> > + struct page *page = follow_page(vma, addr, FOLL_GET);
> > + if (page) {
> > + lock_page(page);
> > + if (page->mapping)
> > + munlock_vma_page(page);
>
> Could you add "please see __mlock_vma_pages_range() to see why" or some here ?
Why the test on page->mapping?
Right, I'll add some such comment on that.
Waiting a day or two to see what else comes up.
Thanks,
Hugh
--
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