linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
To: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org,
	clameter@sgi.com, akpm@linux-foundation.org, ak@suse.de,
	jbarnes@virtuousgeek.org
Subject: Re: [PATCH] change zonelist order v5 [3/3] documentation
Date: Tue, 08 May 2007 13:08:55 -0400	[thread overview]
Message-ID: <1178644135.5203.31.camel@localhost> (raw)
In-Reply-To: <20070508201904.0ee47ca2.kamezawa.hiroyu@jp.fujitsu.com>

On Tue, 2007-05-08 at 20:19 +0900, KAMEZAWA Hiroyuki wrote:
> Patch for documentation.
> 
> Signed-Off-By: KAMEZAWA hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
> 

Will send followup patch with minor editorial changes.
Acked-by:  Lee Schermerhorn <lee.schermerhorn@hp.com>

> 
> ---
>  Documentation/kernel-parameters.txt |   10 +++++++
>  Documentation/sysctl/vm.txt         |   48 ++++++++++++++++++++++++++++++++++++
>  2 files changed, 58 insertions(+)
> 
> Index: linux-2.6.21-mm1/Documentation/kernel-parameters.txt
> ===================================================================
> --- linux-2.6.21-mm1.orig/Documentation/kernel-parameters.txt
> +++ linux-2.6.21-mm1/Documentation/kernel-parameters.txt
> @@ -1233,6 +1233,16 @@ and is between 256 and 4096 characters. 
>  
>  	nr_uarts=	[SERIAL] maximum number of UARTs to be registered.
>  
> +	numa_zonelist_oder= [KNL,BOOT]
> +			Select zonelist order for NUMA. zonelist is used for
> +			desiding where the kernel allocates memory from.
> +			Default is automatic configuration. If "node" is
> +			specified, zonelist is ordered by locality. This can
> +			offer the best locality but possibility of OOM may
> +			increase.  If "zone" is specified, the zonelist is
> +			ordered by zone_type.
> +			See Documentaion/sysctl/vm.txt numa_zonelist_order.
> +			
>  	opl3=		[HW,OSS]
>  			Format: <io>
>  
> Index: linux-2.6.21-mm1/Documentation/sysctl/vm.txt
> ===================================================================
> --- linux-2.6.21-mm1.orig/Documentation/sysctl/vm.txt
> +++ linux-2.6.21-mm1/Documentation/sysctl/vm.txt
> @@ -35,6 +35,7 @@ Currently, these files are in /proc/sys/
>  - stat_interval
>  - readahead_ratio
>  - readahead_hit_rate
> +- numa_zonelist_order
>  
>  ==============================================================
>  
> @@ -293,3 +294,49 @@ Possible values can be:
>  The larger value, the more capabilities, with more possible overheads.
>  
>  The default value is 1.
> +
> +==============================================================
> +
> +numa_zonelist_order
> +
> +This sysctl is only for NUMA.
> +'where the memory is allocated from' is controlled by zonelist.
> +(This documentation ignores ZONE_HIGHMEM/ZONE_DMA32 for simple explanation.
> + you may be able to read ZONE_DMA as ZONE_DMA32...)
> +
> +In non-NUMA case, a zonelist for GFP_KERNEL is ordered as following.
> +ZONE_NORMAL -> ZONE_DMA
> +This means that a memory allocation request for GFP_KERNEL will
> +get memory from ZONE_DMA only when ZONE_NORMAL is not available.
> +
> +In NUMA case, you can think of following 2 types of order.
> +Assume 2 node NUMA and below is zonelist of Node(0)'s GFP_KERNEL
> +
> +(A) Node(0) ZONE_NORMAL -> Node(0) ZONE_DMA -> Node(1) ZONE_NORMAL
> +(B) Node(0) ZONE_NORMAL -> Node(1) ZONE_NORMAL -> Node(0) ZONE_DMA.
> +
> +Type(A) offers the best locality for processes on Node(0), but ZONE_DMA
> +will be used before ZONE_NORMAL exhaustion. This increases possibility of
> +out-of-memory(OOM) of ZONE_DMA because ZONE_DMA is tend to be small.
> +
> +Type(B) cannot offer the best locality but very robust against OOM of DMA zone.
> +
> +Type(A) is called as "Node" order. Type (B) is "Zone" order.
> +
> +"Node order" orders the zonelists by node, then by zone within each node.
> +This will offer the best locality but increases possibility of OOM.
> +Specify "[Nn]ode" for zone order
> +
> +"Zone Order"  preserves the DMA zone as long as possible but
> +results in off-node allocation [for node 0] earlier.
> +Specify "[Zz]one"for zode order.
> +
> +Specify "[Dd]efault" to request automatic configuration.  Autoconfiguration
> +will select "node" order in following case.
> +(1) if the DMA zone does not exist or
> +(2) if the DMA zone comprises greater than 50% of the available memory or
> +(3) if a node's DMA zone comprises greater than 60% of its local memory and
> +    the amount of local memory is enough big.
> +
> +Otherwise, "zone" order will be selected. Default order is recommended unless
> +unless this is causing problems for your system/application.
> 
> --
> To unsubscribe, send a message with 'unsubscribe linux-mm' in
> the body to majordomo@kvack.org.  For more info on Linux MM,
> see: http://www.linux-mm.org/ .
> Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2007-05-08 17:08 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-05-08 11:14 [PATCH] change zonelist order v5 [0/3] KAMEZAWA Hiroyuki
2007-05-08 11:16 ` [PATCH] change zonelist order v5 [1/3] implements zonelist order selection KAMEZAWA Hiroyuki
2007-05-08 17:06   ` Lee Schermerhorn
2007-05-08 17:22     ` Christoph Lameter
2007-05-08 17:33       ` Lee Schermerhorn
2007-05-08 18:05         ` Christoph Lameter
2007-05-08 20:37           ` Lee Schermerhorn
2007-05-09  0:29             ` KAMEZAWA Hiroyuki
2007-05-09  0:58               ` Andrew Morton
2007-05-09  1:07                 ` Christoph Lameter
2007-05-09  1:20                 ` KAMEZAWA Hiroyuki
2007-05-09 13:55                   ` Lee Schermerhorn
2007-05-09  4:12                 ` KAMEZAWA Hiroyuki
2007-05-09  8:53                   ` Andy Whitcroft
2007-05-09  9:04                     ` KAMEZAWA Hiroyuki
2007-05-08 11:18 ` [PATCH] change zonelist order v5 [2/3] automatic configuration KAMEZAWA Hiroyuki
2007-05-08 17:07   ` Lee Schermerhorn
2007-05-08 11:19 ` [PATCH] change zonelist order v5 [3/3] documentation KAMEZAWA Hiroyuki
2007-05-08 17:08   ` Lee Schermerhorn [this message]
2007-05-09  0:23     ` KAMEZAWA Hiroyuki
2007-05-08 12:04 ` [PATCH] change zonelist order v5 [4/3] compile fix KAMEZAWA Hiroyuki
2007-05-08 16:14 ` [PATCH] change zonelist order v5 [0/3] Christoph Lameter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1178644135.5203.31.camel@localhost \
    --to=lee.schermerhorn@hp.com \
    --cc=ak@suse.de \
    --cc=akpm@linux-foundation.org \
    --cc=clameter@sgi.com \
    --cc=jbarnes@virtuousgeek.org \
    --cc=kamezawa.hiroyu@jp.fujitsu.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox