diff options
author | Yasunori Goto <y-goto@jp.fujitsu.com> | 2006-06-27 05:53:30 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-06-27 20:32:35 -0400 |
commit | bc02af93dd2bbddce1b55e0a493f833a1b7cf140 (patch) | |
tree | bda7998531b9c612c5597be9158f082d1cb5ab26 /mm/memory_hotplug.c | |
parent | dd56a8e36f91f63c0a31e8a118d87b7cf01526b8 (diff) |
[PATCH] pgdat allocation for new node add (specify node id)
Change the name of old add_memory() to arch_add_memory. And use node id to
get pgdat for the node at NODE_DATA().
Note: Powerpc's old add_memory() is defined as __devinit. However,
add_memory() is usually called only after bootup.
I suppose it may be redundant. But, I'm not well known about powerpc.
So, I keep it. (But, __meminit is better at least.)
Signed-off-by: Yasunori Goto <y-goto@jp.fujitsu.com>
Cc: Dave Hansen <haveblue@us.ibm.com>
Cc: "Brown, Len" <len.brown@intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'mm/memory_hotplug.c')
-rw-r--r-- | mm/memory_hotplug.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/mm/memory_hotplug.c b/mm/memory_hotplug.c index 841a077d5aeb..6cdeabe9f6d4 100644 --- a/mm/memory_hotplug.c +++ b/mm/memory_hotplug.c | |||
@@ -163,3 +163,14 @@ int online_pages(unsigned long pfn, unsigned long nr_pages) | |||
163 | vm_total_pages = nr_free_pagecache_pages(); | 163 | vm_total_pages = nr_free_pagecache_pages(); |
164 | return 0; | 164 | return 0; |
165 | } | 165 | } |
166 | |||
167 | int add_memory(int nid, u64 start, u64 size) | ||
168 | { | ||
169 | int ret; | ||
170 | |||
171 | /* call arch's memory hotadd */ | ||
172 | ret = arch_add_memory(nid, start, size); | ||
173 | |||
174 | return ret; | ||
175 | } | ||
176 | EXPORT_SYMBOL_GPL(add_memory); | ||