From: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
To: cl@gentwo.org
Cc: akpm@linux-foundation.org, linux-mm@kvack.org, mel@csn.ul.ie
Subject: Re: mm: Do not drain pagevecs for mlockall(MCL_FUTURE)
Date: Mon, 10 Oct 2011 12:15:17 -0400 [thread overview]
Message-ID: <4E931A15.3090400@jp.fujitsu.com> (raw)
In-Reply-To: <alpine.DEB.2.00.1110071529110.15540@router.home>
(10/7/2011 4:32 PM), Christoph Lameter wrote:
> MCL_FUTURE does not move pages between lru list and draining the LRU per
> cpu pagevecs is a nasty activity. Avoid doing it unecessarily.
>
> Signed-off-by: Christoph Lameter <cl@gentwo.org>
>
>
> ---
> mm/mlock.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> Index: linux-2.6/mm/mlock.c
> ===================================================================
> --- linux-2.6.orig/mm/mlock.c 2011-10-07 14:57:52.000000000 -0500
> +++ linux-2.6/mm/mlock.c 2011-10-07 15:01:06.000000000 -0500
> @@ -549,7 +549,8 @@ SYSCALL_DEFINE1(mlockall, int, flags)
> if (!can_do_mlock())
> goto out;
>
> - lru_add_drain_all(); /* flush pagevec */
> + if (flags & MCL_CURRENT)
> + lru_add_drain_all(); /* flush pagevec */
>
> down_write(¤t->mm->mmap_sem);
Looks good to me. I guess I introduced this fault. sorry about that.
Acked-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.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/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2011-10-10 16:12 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-07 20:32 mm: Do not drain pagevecs for mlockall(MCL_FUTURE) Christoph Lameter
2011-10-08 2:45 ` David Rientjes
2011-10-08 4:28 ` Michel Lespinasse
2011-10-08 9:43 ` Minchan Kim
2011-10-10 16:15 ` KOSAKI Motohiro [this message]
2011-10-12 14:57 ` Johannes Weiner
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=4E931A15.3090400@jp.fujitsu.com \
--to=kosaki.motohiro@jp.fujitsu.com \
--cc=akpm@linux-foundation.org \
--cc=cl@gentwo.org \
--cc=linux-mm@kvack.org \
--cc=mel@csn.ul.ie \
/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.