From: Dave Hansen <dave@linux.vnet.ibm.com>
To: Mel Gorman <mgorman@suse.de>
Cc: akpm@osdl.org, linux-kernel@vger.kernel.org,
torvalds@linux-foundation.org, linux-mm@kvack.org
Subject: Re: [PATCH] mm: compaction: Fix return value of capture_free_page
Date: Mon, 26 Nov 2012 07:06:53 -0800 [thread overview]
Message-ID: <50B3858D.2060404@linux.vnet.ibm.com> (raw)
In-Reply-To: <20121126112350.GI8218@suse.de>
On 11/26/2012 03:23 AM, Mel Gorman wrote:
> On Wed, Nov 21, 2012 at 02:21:51PM -0500, Dave Hansen wrote:
>>
>> This needs to make it in before 3.7 is released.
>>
>
> This is also required. Dave, can you double check? The surprise is that
> this does not blow up very obviously.
...
> @@ -1422,7 +1422,7 @@ int capture_free_page(struct page *page, int alloc_order, int migratetype)
> }
> }
>
> - return 1UL << order;
> + return 1UL << alloc_order;
> }
compact_capture_page() only looks at the boolean return value out of
capture_free_page(), so it wouldn't notice. split_free_page() does.
But, when it calls capture_free_page(), order==alloc_order, so it
wouldn't make a difference. So, there's probably no actual bug here,
but it's certainly a wrong return value.
We should probably also fix the set_pageblock_migratetype() loop in
there while we're at it. I think it's potentially trampling on the
migration type of pages currently in the allocator. I _think_ that
completes the list of things that need to get audited in there.
--
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>
next prev parent reply other threads:[~2012-11-26 15:07 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-21 19:21 [PATCH] [3.7-rc] fix incorrect NR_FREE_PAGES accounting (appears like memory leak) Dave Hansen
2012-11-26 11:23 ` [PATCH] mm: compaction: Fix return value of capture_free_page Mel Gorman
2012-11-26 15:06 ` Dave Hansen [this message]
2012-11-27 11:07 ` Mel Gorman
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=50B3858D.2060404@linux.vnet.ibm.com \
--to=dave@linux.vnet.ibm.com \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mgorman@suse.de \
--cc=torvalds@linux-foundation.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;
as well as URLs for NNTP newsgroup(s).