linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Yasunori Goto <y-goto@jp.fujitsu.com>
To: Yinghai Lu <yhlu.kernel@gmail.com>
Cc: Badari Pulavarty <pbadari@us.ibm.com>,
	Linux Kernel ML <linux-kernel@vger.kernel.org>,
	linux-mm <linux-mm@kvack.org>, Andrew Morton <akpm@osdl.org>
Subject: Re: [PATCH 3/3 (RFC)](memory hotplug) align maps for easy removing
Date: Sat, 15 Mar 2008 13:12:21 +0900	[thread overview]
Message-ID: <20080315121118.E4BC.E1E9C6FF@jp.fujitsu.com> (raw)
In-Reply-To: <86802c440803140926n2ec2bd2fscf0f3e9a6e2e4d2e@mail.gmail.com>

> >  Index: current/mm/sparse.c
> >  ===================================================================
> >  --- current.orig/mm/sparse.c    2008-03-11 20:15:41.000000000 +0900
> >  +++ current/mm/sparse.c 2008-03-11 20:58:18.000000000 +0900
> >  @@ -244,7 +244,8 @@
> >         struct mem_section *ms = __nr_to_section(pnum);
> >         int nid = sparse_early_nid(ms);
> >
> >  -       usemap = alloc_bootmem_node(NODE_DATA(nid), usemap_size());
> >  +       usemap = alloc_bootmem_pages_node(NODE_DATA(nid),
> >  +                                         PAGE_ALIGN(usemap_size()));
> 
> if we allocate usemap continuously,
> old way could make different usermap share one page. usermap size is
> only about 24bytes. align to 128bytes ( the SMP cache lines)
> 
> sparse_early_usemap_alloc: usemap = ffff810024e00000 size = 24
> sparse_early_usemap_alloc: usemap = ffff810024e00080 size = 24
> sparse_early_usemap_alloc: usemap = ffff810024e00100 size = 24
> sparse_early_usemap_alloc: usemap = ffff810024e00180 size = 24


Yes, they can share one page. 

I was afraid its page will be hard to remove yesterday.
If all sections' usemaps are allocated on section A,
the other sections (from B to Z) must be removed before section A.
If only one of them are busy, section A can't be removed.
So, I disliked its dependency.

But, I reconsidered it after reading your mail.
The node structures like pgdat has same feature.
If a section has pgdat for the node, it must wait for other section's
removing on the node. So, I'll try to keep same section about pgdat
and shared usemap page.

Anyway, thanks for your comments. 

Bye.

-- 
Yasunori Goto 


--
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:[~2008-03-15  4:12 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-14 14:36 [PATCH 0/3 (RFC)](memory hotplug) freeing pages allocated by bootmem for hotremove Yasunori Goto
2008-03-14 14:38 ` [PATCH 1/3 (RFC)](memory hotplug) remember section_nr and node id for removing Yasunori Goto
2008-03-14 14:41 ` [PATCH 2/3 (RFC)](memory hotplug) free pages allocated by bootmem for hotremove Yasunori Goto
2008-03-14 14:44 ` [PATCH 3/3 (RFC)](memory hotplug) align maps for easy removing Yasunori Goto
2008-03-14 16:26   ` Yinghai Lu
2008-03-15  4:12     ` Yasunori Goto [this message]
2008-03-21 17:05 ` [PATCH 0/3 (RFC)](memory hotplug) freeing pages allocated by bootmem for hotremove Badari Pulavarty
2008-03-22  0:09   ` Yasunori Goto
2008-03-26 22:08     ` Badari Pulavarty

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=20080315121118.E4BC.E1E9C6FF@jp.fujitsu.com \
    --to=y-goto@jp.fujitsu.com \
    --cc=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=pbadari@us.ibm.com \
    --cc=yhlu.kernel@gmail.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