diff options
Diffstat (limited to 'mm')
-rw-r--r-- | mm/memcontrol.c | 6 | ||||
-rw-r--r-- | mm/page_alloc.c | 18 | ||||
-rw-r--r-- | mm/vmstat.c | 3 |
3 files changed, 25 insertions, 2 deletions
diff --git a/mm/memcontrol.c b/mm/memcontrol.c index 82c065e7551e..e93a4db93fbe 100644 --- a/mm/memcontrol.c +++ b/mm/memcontrol.c | |||
@@ -1006,6 +1006,7 @@ static int mem_control_stat_show(struct cgroup *cont, struct cftype *cft, | |||
1006 | { | 1006 | { |
1007 | unsigned long active_anon, inactive_anon; | 1007 | unsigned long active_anon, inactive_anon; |
1008 | unsigned long active_file, inactive_file; | 1008 | unsigned long active_file, inactive_file; |
1009 | unsigned long unevictable; | ||
1009 | 1010 | ||
1010 | inactive_anon = mem_cgroup_get_all_zonestat(mem_cont, | 1011 | inactive_anon = mem_cgroup_get_all_zonestat(mem_cont, |
1011 | LRU_INACTIVE_ANON); | 1012 | LRU_INACTIVE_ANON); |
@@ -1015,10 +1016,15 @@ static int mem_control_stat_show(struct cgroup *cont, struct cftype *cft, | |||
1015 | LRU_INACTIVE_FILE); | 1016 | LRU_INACTIVE_FILE); |
1016 | active_file = mem_cgroup_get_all_zonestat(mem_cont, | 1017 | active_file = mem_cgroup_get_all_zonestat(mem_cont, |
1017 | LRU_ACTIVE_FILE); | 1018 | LRU_ACTIVE_FILE); |
1019 | unevictable = mem_cgroup_get_all_zonestat(mem_cont, | ||
1020 | LRU_UNEVICTABLE); | ||
1021 | |||
1018 | cb->fill(cb, "active_anon", (active_anon) * PAGE_SIZE); | 1022 | cb->fill(cb, "active_anon", (active_anon) * PAGE_SIZE); |
1019 | cb->fill(cb, "inactive_anon", (inactive_anon) * PAGE_SIZE); | 1023 | cb->fill(cb, "inactive_anon", (inactive_anon) * PAGE_SIZE); |
1020 | cb->fill(cb, "active_file", (active_file) * PAGE_SIZE); | 1024 | cb->fill(cb, "active_file", (active_file) * PAGE_SIZE); |
1021 | cb->fill(cb, "inactive_file", (inactive_file) * PAGE_SIZE); | 1025 | cb->fill(cb, "inactive_file", (inactive_file) * PAGE_SIZE); |
1026 | cb->fill(cb, "unevictable", unevictable * PAGE_SIZE); | ||
1027 | |||
1022 | } | 1028 | } |
1023 | return 0; | 1029 | return 0; |
1024 | } | 1030 | } |
diff --git a/mm/page_alloc.c b/mm/page_alloc.c index 79c0981b1d32..4125230a1b2c 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c | |||
@@ -1864,13 +1864,21 @@ void show_free_areas(void) | |||
1864 | } | 1864 | } |
1865 | } | 1865 | } |
1866 | 1866 | ||
1867 | printk("Active_anon:%lu active_file:%lu inactive_anon%lu\n" | 1867 | printk("Active_anon:%lu active_file:%lu inactive_anon:%lu\n" |
1868 | " inactive_file:%lu dirty:%lu writeback:%lu unstable:%lu\n" | 1868 | " inactive_file:%lu" |
1869 | //TODO: check/adjust line lengths | ||
1870 | #ifdef CONFIG_UNEVICTABLE_LRU | ||
1871 | " unevictable:%lu" | ||
1872 | #endif | ||
1873 | " dirty:%lu writeback:%lu unstable:%lu\n" | ||
1869 | " free:%lu slab:%lu mapped:%lu pagetables:%lu bounce:%lu\n", | 1874 | " free:%lu slab:%lu mapped:%lu pagetables:%lu bounce:%lu\n", |
1870 | global_page_state(NR_ACTIVE_ANON), | 1875 | global_page_state(NR_ACTIVE_ANON), |
1871 | global_page_state(NR_ACTIVE_FILE), | 1876 | global_page_state(NR_ACTIVE_FILE), |
1872 | global_page_state(NR_INACTIVE_ANON), | 1877 | global_page_state(NR_INACTIVE_ANON), |
1873 | global_page_state(NR_INACTIVE_FILE), | 1878 | global_page_state(NR_INACTIVE_FILE), |
1879 | #ifdef CONFIG_UNEVICTABLE_LRU | ||
1880 | global_page_state(NR_UNEVICTABLE), | ||
1881 | #endif | ||
1874 | global_page_state(NR_FILE_DIRTY), | 1882 | global_page_state(NR_FILE_DIRTY), |
1875 | global_page_state(NR_WRITEBACK), | 1883 | global_page_state(NR_WRITEBACK), |
1876 | global_page_state(NR_UNSTABLE_NFS), | 1884 | global_page_state(NR_UNSTABLE_NFS), |
@@ -1897,6 +1905,9 @@ void show_free_areas(void) | |||
1897 | " inactive_anon:%lukB" | 1905 | " inactive_anon:%lukB" |
1898 | " active_file:%lukB" | 1906 | " active_file:%lukB" |
1899 | " inactive_file:%lukB" | 1907 | " inactive_file:%lukB" |
1908 | #ifdef CONFIG_UNEVICTABLE_LRU | ||
1909 | " unevictable:%lukB" | ||
1910 | #endif | ||
1900 | " present:%lukB" | 1911 | " present:%lukB" |
1901 | " pages_scanned:%lu" | 1912 | " pages_scanned:%lu" |
1902 | " all_unreclaimable? %s" | 1913 | " all_unreclaimable? %s" |
@@ -1910,6 +1921,9 @@ void show_free_areas(void) | |||
1910 | K(zone_page_state(zone, NR_INACTIVE_ANON)), | 1921 | K(zone_page_state(zone, NR_INACTIVE_ANON)), |
1911 | K(zone_page_state(zone, NR_ACTIVE_FILE)), | 1922 | K(zone_page_state(zone, NR_ACTIVE_FILE)), |
1912 | K(zone_page_state(zone, NR_INACTIVE_FILE)), | 1923 | K(zone_page_state(zone, NR_INACTIVE_FILE)), |
1924 | #ifdef CONFIG_UNEVICTABLE_LRU | ||
1925 | K(zone_page_state(zone, NR_UNEVICTABLE)), | ||
1926 | #endif | ||
1913 | K(zone->present_pages), | 1927 | K(zone->present_pages), |
1914 | zone->pages_scanned, | 1928 | zone->pages_scanned, |
1915 | (zone_is_all_unreclaimable(zone) ? "yes" : "no") | 1929 | (zone_is_all_unreclaimable(zone) ? "yes" : "no") |
diff --git a/mm/vmstat.c b/mm/vmstat.c index 6cb08cdd4f03..6db2f6319313 100644 --- a/mm/vmstat.c +++ b/mm/vmstat.c | |||
@@ -623,6 +623,9 @@ static const char * const vmstat_text[] = { | |||
623 | "nr_active_anon", | 623 | "nr_active_anon", |
624 | "nr_inactive_file", | 624 | "nr_inactive_file", |
625 | "nr_active_file", | 625 | "nr_active_file", |
626 | #ifdef CONFIG_UNEVICTABLE_LRU | ||
627 | "nr_unevictable", | ||
628 | #endif | ||
626 | "nr_anon_pages", | 629 | "nr_anon_pages", |
627 | "nr_mapped", | 630 | "nr_mapped", |
628 | "nr_file_pages", | 631 | "nr_file_pages", |