diff options
author | Konstantin Khlebnikov <koct9i@gmail.com> | 2015-04-14 18:45:32 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2015-04-14 19:49:01 -0400 |
commit | 761b06771adeeb734e9eebc6f70f916cb9e2f643 (patch) | |
tree | 0d782b6eb7071af9530cd693854d2f3ab32d9d4d | |
parent | d1bfcdb8ce0ea6eb6034daa7ff02548e0bc9c21b (diff) |
mm: completely remove dumping per-cpu lists from show_mem()
It seems nobody needs this.
Signed-off-by: Konstantin Khlebnikov <koct9i@gmail.com>
Cc: Michal Hocko <mhocko@suse.cz>
Cc: David Rientjes <rientjes@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | include/linux/mm.h | 1 | ||||
-rw-r--r-- | mm/page_alloc.c | 22 |
2 files changed, 2 insertions, 21 deletions
diff --git a/include/linux/mm.h b/include/linux/mm.h index 9c21b42d07bf..6571dd78e984 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h | |||
@@ -1126,7 +1126,6 @@ extern void pagefault_out_of_memory(void); | |||
1126 | * various contexts. | 1126 | * various contexts. |
1127 | */ | 1127 | */ |
1128 | #define SHOW_MEM_FILTER_NODES (0x0001u) /* disallowed nodes */ | 1128 | #define SHOW_MEM_FILTER_NODES (0x0001u) /* disallowed nodes */ |
1129 | #define SHOW_MEM_PERCPU_LISTS (0x0002u) /* per-zone per-cpu */ | ||
1130 | 1129 | ||
1131 | extern void show_free_areas(unsigned int flags); | 1130 | extern void show_free_areas(unsigned int flags); |
1132 | extern bool skip_free_areas_node(unsigned int flags, int nid); | 1131 | extern bool skip_free_areas_node(unsigned int flags, int nid); |
diff --git a/mm/page_alloc.c b/mm/page_alloc.c index eab8e2018a46..84466a4b1b36 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c | |||
@@ -3255,7 +3255,6 @@ static void show_migration_types(unsigned char type) | |||
3255 | * Bits in @filter: | 3255 | * Bits in @filter: |
3256 | * SHOW_MEM_FILTER_NODES: suppress nodes that are not allowed by current's | 3256 | * SHOW_MEM_FILTER_NODES: suppress nodes that are not allowed by current's |
3257 | * cpuset. | 3257 | * cpuset. |
3258 | * SHOW_MEM_PERCPU_LISTS: display full per-node per-cpu pcp lists | ||
3259 | */ | 3258 | */ |
3260 | void show_free_areas(unsigned int filter) | 3259 | void show_free_areas(unsigned int filter) |
3261 | { | 3260 | { |
@@ -3267,25 +3266,8 @@ void show_free_areas(unsigned int filter) | |||
3267 | if (skip_free_areas_node(filter, zone_to_nid(zone))) | 3266 | if (skip_free_areas_node(filter, zone_to_nid(zone))) |
3268 | continue; | 3267 | continue; |
3269 | 3268 | ||
3270 | if (filter & SHOW_MEM_PERCPU_LISTS) { | 3269 | for_each_online_cpu(cpu) |
3271 | show_node(zone); | 3270 | free_pcp += per_cpu_ptr(zone->pageset, cpu)->pcp.count; |
3272 | printk("%s per-cpu:\n", zone->name); | ||
3273 | } | ||
3274 | |||
3275 | for_each_online_cpu(cpu) { | ||
3276 | struct per_cpu_pageset *pageset; | ||
3277 | |||
3278 | pageset = per_cpu_ptr(zone->pageset, cpu); | ||
3279 | |||
3280 | free_pcp += pageset->pcp.count; | ||
3281 | |||
3282 | if (!(filter & SHOW_MEM_PERCPU_LISTS)) | ||
3283 | continue; | ||
3284 | |||
3285 | printk("CPU %4d: hi:%5d, btch:%4d usd:%4d\n", | ||
3286 | cpu, pageset->pcp.high, | ||
3287 | pageset->pcp.batch, pageset->pcp.count); | ||
3288 | } | ||
3289 | } | 3271 | } |
3290 | 3272 | ||
3291 | printk("active_anon:%lu inactive_anon:%lu isolated_anon:%lu\n" | 3273 | printk("active_anon:%lu inactive_anon:%lu isolated_anon:%lu\n" |