aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/linux/vmstat.h3
-rw-r--r--mm/vmscan.c3
-rw-r--r--mm/vmstat.c3
3 files changed, 9 insertions, 0 deletions
diff --git a/include/linux/vmstat.h b/include/linux/vmstat.h
index 524cd1b28ec..cfdd3cae888 100644
--- a/include/linux/vmstat.h
+++ b/include/linux/vmstat.h
@@ -36,6 +36,9 @@ enum vm_event_item { PGPGIN, PGPGOUT, PSWPIN, PSWPOUT,
FOR_ALL_ZONES(PGSTEAL),
FOR_ALL_ZONES(PGSCAN_KSWAPD),
FOR_ALL_ZONES(PGSCAN_DIRECT),
+#ifdef CONFIG_NUMA
+ PGSCAN_ZONE_RECLAIM_FAILED,
+#endif
PGINODESTEAL, SLABS_SCANNED, KSWAPD_STEAL, KSWAPD_INODESTEAL,
PAGEOUTRUN, ALLOCSTALL, PGROTATED,
#ifdef CONFIG_HUGETLB_PAGE
diff --git a/mm/vmscan.c b/mm/vmscan.c
index d51e9937ff2..2500b01e7a7 100644
--- a/mm/vmscan.c
+++ b/mm/vmscan.c
@@ -2452,6 +2452,9 @@ int zone_reclaim(struct zone *zone, gfp_t gfp_mask, unsigned int order)
ret = __zone_reclaim(zone, gfp_mask, order);
zone_clear_flag(zone, ZONE_RECLAIM_LOCKED);
+ if (!ret)
+ count_vm_event(PGSCAN_ZONE_RECLAIM_FAILED);
+
return ret;
}
#endif
diff --git a/mm/vmstat.c b/mm/vmstat.c
index 74d66dba0cb..ddb360a09ef 100644
--- a/mm/vmstat.c
+++ b/mm/vmstat.c
@@ -675,6 +675,9 @@ static const char * const vmstat_text[] = {
TEXTS_FOR_ZONES("pgscan_kswapd")
TEXTS_FOR_ZONES("pgscan_direct")
+#ifdef CONFIG_NUMA
+ "zone_reclaim_failed",
+#endif
"pginodesteal",
"slabs_scanned",
"kswapd_steal",