summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>2009-09-21 17:01:31 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2009-09-22 07:17:27 -0700
commit71de1ccbe1fb40203edd3beb473f8580d917d2ca (patch)
tree63417ce9538883348350a879bf359e6100c244de
parent4a0aa73f1d613bf19bc8610bf090c941ef49d720 (diff)
downloadlinux-stable-71de1ccbe1fb40203edd3beb473f8580d917d2ca.tar.gz
linux-stable-71de1ccbe1fb40203edd3beb473f8580d917d2ca.tar.bz2
linux-stable-71de1ccbe1fb40203edd3beb473f8580d917d2ca.zip
mm: oom analysis: add buffer cache information to show_free_areas()
It is often useful to know the statistics for all pages that are handled like page cache pages when looking at OOM log output. Therefore show_free_areas() should also display buffer cache statistics. Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Acked-by: Wu Fengguang <fengguang.wu@intel.com> Reviewed-by: Rik van Riel <riel@redhat.com> 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--mm/page_alloc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/mm/page_alloc.c b/mm/page_alloc.c
index 8fbf5a4f5cf7..494c09196c30 100644
--- a/mm/page_alloc.c
+++ b/mm/page_alloc.c
@@ -2137,7 +2137,7 @@ void show_free_areas(void)
printk("Active_anon:%lu active_file:%lu inactive_anon:%lu\n"
" inactive_file:%lu"
" unevictable:%lu"
- " dirty:%lu writeback:%lu unstable:%lu\n"
+ " dirty:%lu writeback:%lu unstable:%lu buffer:%lu\n"
" free:%lu slab_reclaimable:%lu slab_unreclaimable:%lu\n"
" mapped:%lu pagetables:%lu bounce:%lu\n",
global_page_state(NR_ACTIVE_ANON),
@@ -2148,6 +2148,7 @@ void show_free_areas(void)
global_page_state(NR_FILE_DIRTY),
global_page_state(NR_WRITEBACK),
global_page_state(NR_UNSTABLE_NFS),
+ nr_blockdev_pages(),
global_page_state(NR_FREE_PAGES),
global_page_state(NR_SLAB_RECLAIMABLE),
global_page_state(NR_SLAB_UNRECLAIMABLE),