lkml.org 
[lkml]   [2009]   [Jul]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/5] add per-zone statistics to show_free_areas()
On Sun, Jul 05, 2009 at 05:23:35PM +0800, KOSAKI Motohiro wrote:
> Subject: [PATCH] add per-zone statistics to show_free_areas()
>
> Currently, show_free_area() mainly display system memory usage. but it
> doesn't display per-zone memory usage information.
>
> However, if DMA zone OOM occur, Administrator definitely need to know
> per-zone memory usage information.

DMA zone is normally lowmem-reserved. But I think the numbers still
make sense for DMA32.

Acked-by: Wu Fengguang <fengguang.wu@intel.com>

>
>
> Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
> ---
> mm/page_alloc.c | 20 ++++++++++++++++++++
> 1 file changed, 20 insertions(+)
>
> Index: b/mm/page_alloc.c
> ===================================================================
> --- a/mm/page_alloc.c
> +++ b/mm/page_alloc.c
> @@ -2151,6 +2151,16 @@ void show_free_areas(void)
> " inactive_file:%lukB"
> " unevictable:%lukB"
> " present:%lukB"
> + " mlocked:%lukB"
> + " dirty:%lukB"
> + " writeback:%lukB"
> + " mapped:%lukB"
> + " slab_reclaimable:%lukB"
> + " slab_unreclaimable:%lukB"
> + " pagetables:%lukB"
> + " unstable:%lukB"
> + " bounce:%lukB"
> + " writeback_tmp:%lukB"
> " pages_scanned:%lu"
> " all_unreclaimable? %s"
> "\n",
> @@ -2165,6 +2175,16 @@ void show_free_areas(void)
> K(zone_page_state(zone, NR_INACTIVE_FILE)),
> K(zone_page_state(zone, NR_UNEVICTABLE)),
> K(zone->present_pages),
> + K(zone_page_state(zone, NR_MLOCK)),
> + K(zone_page_state(zone, NR_FILE_DIRTY)),
> + K(zone_page_state(zone, NR_WRITEBACK)),
> + K(zone_page_state(zone, NR_FILE_MAPPED)),
> + K(zone_page_state(zone, NR_SLAB_RECLAIMABLE)),
> + K(zone_page_state(zone, NR_SLAB_UNRECLAIMABLE)),
> + K(zone_page_state(zone, NR_PAGETABLE)),
> + K(zone_page_state(zone, NR_UNSTABLE_NFS)),
> + K(zone_page_state(zone, NR_BOUNCE)),
> + K(zone_page_state(zone, NR_WRITEBACK_TEMP)),
> zone->pages_scanned,
> (zone_is_all_unreclaimable(zone) ? "yes" : "no")
> );
>


\
 
 \ /
  Last update: 2009-07-05 13:09    [W:0.700 / U:0.036 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site