All of lore.kernel.org
 help / color / mirror / Atom feed
From: Martin Hicks <mort@sgi.com>
To: Lee Schermerhorn <lee.schermerhorn@hp.com>
Cc: linux-mm <linux-mm@kvack.org>, Martin Hicks <mort@sgi.com>,
	lhms-devel <lhms-devel@lists.sourceforge.net>
Subject: Re: [PATCH] shrink_list skip anon pages if not may_swap
Date: Mon, 12 Sep 2005 21:21:08 -0400	[thread overview]
Message-ID: <20050913012108.GY13449@localhost> (raw)
In-Reply-To: <1126546191.5182.29.camel@localhost.localdomain>

On Mon, Sep 12, 2005 at 01:29:51PM -0400, Lee Schermerhorn wrote:
> 
> Cc to lhms-devel because memory hotplug page migration also uses
> shrink_list.
> 
> Signed-off-by:  Lee Schermerhorn <lee.schermerhorn@hp.com>

Acked-by: Martin Hicks <mort@sgi.com>


Lee already e-mail me privately about this issue.  Nice catch indeed.

thanks
mh

> ============================================================
> --- shrink_list-skip-anon-pages-if-not-may_swap/mm/vmscan.c~original	2005-08-28 19:41:01.000000000 -0400
> +++ shrink_list-skip-anon-pages-if-not-may_swap/mm/vmscan.c	2005-09-12 10:17:01.000000000 -0400
> @@ -417,7 +417,9 @@ static int shrink_list(struct list_head 
>  		 * Anonymous process memory has backing store?
>  		 * Try to allocate it some swap space here.
>  		 */
> -		if (PageAnon(page) && !PageSwapCache(page) && sc->may_swap) {
> +		if (PageAnon(page) && !PageSwapCache(page)) {
> +			if (!sc->may_swap)
> +				goto keep_locked;
>  			if (!add_to_swap(page))
>  				goto activate_locked;
>  		}
> 
> 

-- 
Martin Hicks   ||   Silicon Graphics Inc.   ||   mort@sgi.com
--
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>

      parent reply	other threads:[~2005-09-13  1:21 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-09-12 17:29 [PATCH] shrink_list skip anon pages if not may_swap Lee Schermerhorn
2005-09-12 23:21 ` Rik van Riel
2005-09-13  1:21 ` Martin Hicks [this message]

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=20050913012108.GY13449@localhost \
    --to=mort@sgi.com \
    --cc=lee.schermerhorn@hp.com \
    --cc=lhms-devel@lists.sourceforge.net \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.