From: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
To: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Andy Whitcroft <apw@shadowen.org>,
Dave Hansen <haveblue@us.ibm.com>,
Gerald Schaefer <gerald.schaefer@de.ibm.com>,
linux-kernel@vger.kernel.org, linux-mm@kvack.org
Subject: Re: [PATCH] memory_hotplug: always initialize pageblock bitmap.
Date: Fri, 9 May 2008 15:39:10 +0900 [thread overview]
Message-ID: <20080509153910.6b074a30.kamezawa.hiroyu@jp.fujitsu.com> (raw)
In-Reply-To: <20080509060609.GB9840@osiris.boeblingen.de.ibm.com>
On Fri, 9 May 2008 08:06:09 +0200
Heiko Carstens <heiko.carstens@de.ibm.com> wrote:
> From: Heiko Carstens <heiko.carstens@de.ibm.com>
>
> Trying to online a new memory section that was added via memory hotplug
> sometimes results in crashes when the new pages are added via
> __free_page. Reason for that is that the pageblock bitmap isn't
> initialized and hence contains random stuff.
Hmm, curious. In my understanding, memmap_init_zone() initializes it.
__add_pages()
-> __add_section()
-> sparse-add_one_section() // allocate usemap
-> __add_zone()
-> memmap_init_zone() // reset pageblock's bitmap
Can't memmap_init_zone() does proper initialization ?
........................
Ah, ok. I see. grow_zone_span() is not called at __add_zone(), then,
memmap_init_zone() doesn't initialize usemap because memmap is not in zone's
range.
Recently, I added a check "zone's start_pfn < pfn < zone's end"
to memmap_init_zone()'s usemap initialization for !SPARSEMEM case bug FIX.
(and I think the fix itself is sane.)
How about calling grow_pgdat_span()/grow_zone_span() from __add_zone() ?
Thanks,
-Kame
--
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:[~2008-05-09 6:39 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-09 6:06 Heiko Carstens, Heiko Carstens
2008-05-09 6:39 ` KAMEZAWA Hiroyuki [this message]
2008-05-09 6:45 ` Heiko Carstens
2008-05-10 12:45 ` Heiko Carstens
2008-05-12 1:55 ` KAMEZAWA Hiroyuki
2008-05-12 9:19 ` KAMEZAWA Hiroyuki
2008-05-13 11:58 ` Heiko Carstens, Heiko Carstens
2008-05-13 18:52 ` Heiko Carstens
2008-05-14 0:52 ` KAMEZAWA Hiroyuki
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=20080509153910.6b074a30.kamezawa.hiroyu@jp.fujitsu.com \
--to=kamezawa.hiroyu@jp.fujitsu.com \
--cc=akpm@linux-foundation.org \
--cc=apw@shadowen.org \
--cc=gerald.schaefer@de.ibm.com \
--cc=haveblue@us.ibm.com \
--cc=heiko.carstens@de.ibm.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