if (ptep_clear_flush_young(vma, address, pte))
referenced++;
- if (mm != current->mm && has_swap_token(mm))
- referenced++;
-
(*mapcount)--;
out_unmap:
* an exclusive swap page, do_wp_page will replace it by a copy
* page, and the user never get to see the data GUP was holding
* the original page for.
- *
- * This test is also useful for when swapoff (unuse_process) has
- * to drop page lock: its reference to the page stops existing
- * ptes from being unmapped, so swapoff can make progress.
*/
if (PageSwapCache(page) &&
page_count(page) != page->mapcount + 2) {
page_remove_rmap(page);
page_cache_release(page);
- // mm->rss--;
- vx_rsspages_dec(mm);
+ mm->rss--;
(*mapcount)--;
}