Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756094Ab2F0Fyu (ORCPT ); Wed, 27 Jun 2012 01:54:50 -0400 Received: from fgwmail6.fujitsu.co.jp ([192.51.44.36]:58189 "EHLO fgwmail6.fujitsu.co.jp" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751420Ab2F0Fyt (ORCPT ); Wed, 27 Jun 2012 01:54:49 -0400 X-SecurityPolicyCheck: OK by SHieldMailChecker v1.7.4 Message-ID: <4FEAA019.7070302@jp.fujitsu.com> Date: Wed, 27 Jun 2012 14:54:33 +0900 From: Yasuaki Ishimatsu User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:13.0) Gecko/20120614 Thunderbird/13.0.1 MIME-Version: 1.0 To: , , , CC: , , , , , , , Subject: [RFC PATCH 8/12] memory-hotplug : move register_page_bootmem_info_node and put_page_bootmem for sparse-vmemmap References: <4FEA9C88.1070800@jp.fujitsu.com> In-Reply-To: <4FEA9C88.1070800@jp.fujitsu.com> Content-Type: text/plain; charset="ISO-2022-JP" Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 3060 Lines: 87 For implementing register_page_bootmem_info_node of sparse-vmemmap, register_page_bootmem_info_node and put_page_bootmem are moved to memory_hotplug.c CC: Len Brown CC: Benjamin Herrenschmidt CC: Paul Mackerras CC: Christoph Lameter Cc: Minchan Kim CC: Andrew Morton CC: KOSAKI Motohiro CC: Wen Congyan Signed-off-by: Yasuaki Ishimatsu --- include/linux/memory_hotplug.h | 9 --------- mm/memory_hotplug.c | 8 ++++++-- 2 files changed, 6 insertions(+), 11 deletions(-) Index: linux-3.5-rc4/include/linux/memory_hotplug.h =================================================================== --- linux-3.5-rc4.orig/include/linux/memory_hotplug.h 2012-06-26 13:56:34.372988299 +0900 +++ linux-3.5-rc4/include/linux/memory_hotplug.h 2012-06-26 14:05:16.603459518 +0900 @@ -160,17 +160,8 @@ static inline void arch_refresh_nodedata #endif /* CONFIG_NUMA */ #endif /* CONFIG_HAVE_ARCH_NODEDATA_EXTENSION */ -#ifdef CONFIG_SPARSEMEM_VMEMMAP -static inline void register_page_bootmem_info_node(struct pglist_data *pgdat) -{ -} -static inline void put_page_bootmem(struct page *page) -{ -} -#else extern void register_page_bootmem_info_node(struct pglist_data *pgdat); extern void put_page_bootmem(struct page *page); -#endif /* * Lock for memory hotplug guarantees 1) all callbacks for memory hotplug Index: linux-3.5-rc4/mm/memory_hotplug.c =================================================================== --- linux-3.5-rc4.orig/mm/memory_hotplug.c 2012-06-26 14:03:37.564697621 +0900 +++ linux-3.5-rc4/mm/memory_hotplug.c 2012-06-26 14:05:16.604459506 +0900 @@ -91,7 +91,6 @@ static void release_memory_resource(stru } #ifdef CONFIG_MEMORY_HOTPLUG_SPARSE -#ifndef CONFIG_SPARSEMEM_VMEMMAP static void get_page_bootmem(unsigned long info, struct page *page, unsigned long type) { @@ -127,6 +126,7 @@ void __ref put_page_bootmem(struct page } +#ifndef CONFIG_SPARSEMEM_VMEMMAP static void register_page_bootmem_info_section(unsigned long start_pfn) { unsigned long *usemap, mapsize, section_nr, i; @@ -163,6 +163,11 @@ static void register_page_bootmem_info_s get_page_bootmem(section_nr, page, MIX_SECTION_INFO); } +#else +static inline void register_page_bootmem_info_section(unsigned long start_pfn) +{ +} +#endif void register_page_bootmem_info_node(struct pglist_data *pgdat) { @@ -198,7 +203,6 @@ void register_page_bootmem_info_node(str register_page_bootmem_info_section(pfn); } -#endif /* !CONFIG_SPARSEMEM_VMEMMAP */ static void grow_zone_span(struct zone *zone, unsigned long start_pfn, unsigned long end_pfn) -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/