|
@@ -283,7 +283,10 @@ static int page_referenced_one(struct page *page,
|
|
if (!pte)
|
|
if (!pte)
|
|
goto out;
|
|
goto out;
|
|
|
|
|
|
- if (ptep_clear_flush_young(vma, address, pte))
|
|
|
|
|
|
+ if (vma->vm_flags & VM_LOCKED) {
|
|
|
|
+ referenced++;
|
|
|
|
+ *mapcount = 1; /* break early from loop */
|
|
|
|
+ } else if (ptep_clear_flush_young(vma, address, pte))
|
|
referenced++;
|
|
referenced++;
|
|
|
|
|
|
/* Pretend the page is referenced if the task has the
|
|
/* Pretend the page is referenced if the task has the
|