summaryrefslogtreecommitdiff
path: root/mm/filemap.c
diff options
context:
space:
mode:
authorVinayak Menon <vinmenon@codeaurora.org>2015-07-13 13:24:55 +0530
committerDavid Keitel <dkeitel@codeaurora.org>2016-03-25 16:03:59 -0700
commite74a8a432ef2193d83f3dcea5bef9d02ca3b0999 (patch)
treeb3bc4641db9b33e39def3bf302ee545fc54bf2d2 /mm/filemap.c
parent1c5466dbec98409c5882f297385d0730abab6cbb (diff)
mm: vmstat: add pageoutclean
vmstat events currently count pgpgout, but that includes only the writebacks, and not the reclaim of clean pages. Add an event to count clean page evictions. This is helpful to evaluate page thrashing cases. Change-Id: Icfb797877a544a58c289074bdc290dfbc1384514 Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
Diffstat (limited to 'mm/filemap.c')
-rw-r--r--mm/filemap.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/mm/filemap.c b/mm/filemap.c
index 1bb007624b53..a322c035c6b9 100644
--- a/mm/filemap.c
+++ b/mm/filemap.c
@@ -189,10 +189,12 @@ void __delete_from_page_cache(struct page *page, void *shadow,
* invalidate any existing cleancache entries. We can't leave
* stale data around in the cleancache once our page is gone
*/
- if (PageUptodate(page) && PageMappedToDisk(page))
+ if (PageUptodate(page) && PageMappedToDisk(page)) {
+ count_vm_event(PGPGOUTCLEAN);
cleancache_put_page(page);
- else
+ } else {
cleancache_invalidate_page(mapping, page);
+ }
page_cache_tree_delete(mapping, page, shadow);