linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Christoph Lameter <cl@linux-foundation.org>
To: Bob Liu <lliubbo@gmail.com>
Cc: Mel Gorman <mel@csn.ul.ie>,
	kamezawa.hiroyu@jp.fujitsu.com, minchan.kim@gmail.com,
	akpm@linux-foundation.org, linux-mm@kvack.org,
	andi@firstfloor.org, rientjes@google.com,
	lee.schermerhorn@hp.com
Subject: Re: [PATCH] mempolicy:add GFP_THISNODE when allocing new page
Date: Fri, 16 Apr 2010 10:55:07 -0500 (CDT)	[thread overview]
Message-ID: <alpine.DEB.2.00.1004161049130.7710@router.home> (raw)
In-Reply-To: <o2kcf18f8341004160803v9663d602g8813b639024b5eca@mail.gmail.com>

On Fri, 16 Apr 2010, Bob Liu wrote:

> Hmm.
> What about this change? If the from_nodes and to_nodes' weight is different,
> then we can don't preserv of the relative position of the page to the beginning
> of the node set. This case if a page allocation from the dest node
> failed, it will
> be allocated from the next node instead of early return.

Understand what you are doing first. The fallback is already there.

> diff --git a/mm/mempolicy.c b/mm/mempolicy.c
> index 08f40a2..094d092 100644
> --- a/mm/mempolicy.c
> +++ b/mm/mempolicy.c
> @@ -842,7 +842,8 @@ static void migrate_page_add(struct page *page,
> struct list_head *pagelist,
>
>  static struct page *new_node_page(struct page *page, unsigned long
> node, int **x)
>  {
> -       return alloc_pages_exact_node(node, GFP_HIGHUSER_MOVABLE, 0);
> +       return alloc_pages_exact_node(node,
> +                       GFP_HIGHUSER_MOVABLE | GFP_THISNODE, 0);

You eliminate falling back to the next node?

GFP_THISNODE forces allocation from the node. Without it we will fallback.

--
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:[~2010-04-16 15:55 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-06  2:59 Bob Liu
2010-04-06  4:33 ` Minchan Kim
2010-04-06  4:56   ` Bob Liu
2010-04-06  5:06     ` Minchan Kim
2010-04-13  8:19 ` KAMEZAWA Hiroyuki
2010-04-13  8:20 ` Bob Liu
2010-04-13  8:38   ` Mel Gorman
2010-04-13 14:28     ` Bob Liu
2010-04-16  0:41       ` Christoph Lameter
2010-04-16  1:02         ` Bob Liu
2010-04-16 16:02           ` Christoph Lameter
2010-04-16 11:15       ` Mel Gorman
2010-04-16 15:03         ` Bob Liu
2010-04-16 15:55           ` Christoph Lameter [this message]
2010-04-17 13:54             ` Bob Liu
2010-04-19 17:47               ` Christoph Lameter
2010-04-20  2:08                 ` Bob Liu
2010-04-21 14:13                   ` Christoph Lameter
2010-04-22  1:03                     ` Bob Liu
2010-04-22 14:38                       ` Christoph Lameter
2010-04-13  8:27 ` Minchan Kim

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=alpine.DEB.2.00.1004161049130.7710@router.home \
    --to=cl@linux-foundation.org \
    --cc=akpm@linux-foundation.org \
    --cc=andi@firstfloor.org \
    --cc=kamezawa.hiroyu@jp.fujitsu.com \
    --cc=lee.schermerhorn@hp.com \
    --cc=linux-mm@kvack.org \
    --cc=lliubbo@gmail.com \
    --cc=mel@csn.ul.ie \
    --cc=minchan.kim@gmail.com \
    --cc=rientjes@google.com \
    /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