diff --git a/[refs] b/[refs] index c0747676ef67..f578b3bf6591 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: b62e408c05228f40e69bb38a48db8961cac6cd23 +refs/heads/master: 03ef83af528899aa339e42d8024b37e2f434fba4 diff --git a/trunk/mm/rmap.c b/trunk/mm/rmap.c index 836c6c63e1f2..0895b5c7cbff 100644 --- a/trunk/mm/rmap.c +++ b/trunk/mm/rmap.c @@ -358,6 +358,7 @@ static int page_referenced_one(struct page *page, */ if (vma->vm_flags & VM_LOCKED) { *mapcount = 1; /* break early from loop */ + *vm_flags |= VM_LOCKED; goto out_unmap; } diff --git a/trunk/mm/vmscan.c b/trunk/mm/vmscan.c index dea7abd31098..94e86dd6954c 100644 --- a/trunk/mm/vmscan.c +++ b/trunk/mm/vmscan.c @@ -630,9 +630,14 @@ static unsigned long shrink_page_list(struct list_head *page_list, referenced = page_referenced(page, 1, sc->mem_cgroup, &vm_flags); - /* In active use or really unfreeable? Activate it. */ + /* + * In active use or really unfreeable? Activate it. + * If page which have PG_mlocked lost isoltation race, + * try_to_unmap moves it to unevictable list + */ if (sc->order <= PAGE_ALLOC_COSTLY_ORDER && - referenced && page_mapping_inuse(page)) + referenced && page_mapping_inuse(page) + && !(vm_flags & VM_LOCKED)) goto activate_locked; /*