diff options
Diffstat (limited to 'mm/rmap.c')
-rw-r--r-- | mm/rmap.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -298,7 +298,11 @@ static int page_referenced_one(struct page *page, | |||
298 | if (ptep_clear_flush_young(vma, address, pte)) | 298 | if (ptep_clear_flush_young(vma, address, pte)) |
299 | referenced++; | 299 | referenced++; |
300 | 300 | ||
301 | if (mm != current->mm && !ignore_token && has_swap_token(mm)) | 301 | /* Pretend the page is referenced if the task has the |
302 | swap token and is in the middle of a page fault. */ | ||
303 | if (mm != current->mm && !ignore_token && | ||
304 | has_swap_token(mm) && | ||
305 | rwsem_is_locked(&mm->mmap_sem)) | ||
302 | referenced++; | 306 | referenced++; |
303 | 307 | ||
304 | (*mapcount)--; | 308 | (*mapcount)--; |