> >
> > How about this fix?
> >
> > ---
> > mm: stop circulating of referenced mlocked pages
> >
> > Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
> > ---
> >
> > --- linux.orig/mm/rmap.c 2009-08-16 19:11:13.000000000 +0800
> > +++ linux/mm/rmap.c 2009-08-16 19:22:46.000000000 +0800
> > @@ -358,6 +358,7 @@ static int page_referenced_one(struct pa
> > */
> > if (vma->vm_flags & VM_LOCKED) {
> > *mapcount = 1; /* break early from loop */
> > + *vm_flags |= VM_LOCKED;
> > goto out_unmap;
> > }
> >
> > @@ -482,6 +483,8 @@ static int page_referenced_file(struct p
> > }
> >
> > spin_unlock(&mapping->i_mmap_lock);
> > + if (*vm_flags & VM_LOCKED)
> > + referenced = 0;
> > return referenced;
> > }
> >
> >
> > --
> > 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: <a href=mailto:"dont@kvack.org">
email@kvack.org </a>
> >
>
>
>
> --
> Kind regards,
> Minchan Kim