summaryrefslogtreecommitdiffstats
path: root/mm/vmstat.c
diff options
context:
space:
mode:
authorAndi Kleen <ak@linux.intel.com>2011-04-14 15:22:06 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2011-04-14 16:06:55 -0700
commit81ab4201fb7d91d6b0cd9ad5b4b16776e4bed145 (patch)
tree92f57a83fa43ac8f742ddb227a397028ab022afc /mm/vmstat.c
parentc897401bac2b099dd2ff673a9afe7193723d253c (diff)
downloadlinux-81ab4201fb7d91d6b0cd9ad5b4b16776e4bed145.tar.gz
linux-81ab4201fb7d91d6b0cd9ad5b4b16776e4bed145.tar.bz2
linux-81ab4201fb7d91d6b0cd9ad5b4b16776e4bed145.zip
mm: add VM counters for transparent hugepages
I found it difficult to make sense of transparent huge pages without having any counters for its actions. Add some counters to vmstat for allocation of transparent hugepages and fallback to smaller pages. Optional patch, but useful for development and understanding the system. Contains improvements from Andrea Arcangeli and Johannes Weiner [akpm@linux-foundation.org: coding-style fixes] [hannes@cmpxchg.org: fix vmstat_text[] entries] Signed-off-by: Andi Kleen <ak@linux.intel.com> Acked-by: Andrea Arcangeli <aarcange@redhat.com> Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> Signed-off-by: Johannes Weiner <hannes@cmpxchg.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/vmstat.c')
-rw-r--r--mm/vmstat.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/mm/vmstat.c b/mm/vmstat.c
index 8cb0f0a703e5..897ea9e88238 100644
--- a/mm/vmstat.c
+++ b/mm/vmstat.c
@@ -948,7 +948,16 @@ static const char * const vmstat_text[] = {
"unevictable_pgs_cleared",
"unevictable_pgs_stranded",
"unevictable_pgs_mlockfreed",
+
+#ifdef CONFIG_TRANSPARENT_HUGEPAGE
+ "thp_fault_alloc",
+ "thp_fault_fallback",
+ "thp_collapse_alloc",
+ "thp_collapse_alloc_failed",
+ "thp_split",
#endif
+
+#endif /* CONFIG_VM_EVENTS_COUNTERS */
};
static void zoneinfo_show_print(struct seq_file *m, pg_data_t *pgdat,