From patchwork Thu Dec 8 22:33:29 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Rientjes X-Patchwork-Id: 130247 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from ozlabs.org (localhost [IPv6:::1]) by ozlabs.org (Postfix) with ESMTP id A1DBD100807 for ; Fri, 9 Dec 2011 09:33:51 +1100 (EST) Received: from mail-iy0-f179.google.com (mail-iy0-f179.google.com [209.85.210.179]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority" (verified OK)) by ozlabs.org (Postfix) with ESMTPS id B2C851007D7 for ; Fri, 9 Dec 2011 09:33:35 +1100 (EST) Received: by iacb35 with SMTP id b35so3148474iac.38 for ; Thu, 08 Dec 2011 14:33:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=beta; h=date:from:x-x-sender:to:cc:subject:in-reply-to:message-id :references:user-agent:mime-version:content-type; bh=PHaG8KEypWT0ORlW+U0fTgNuMyyCll2bsfXOEfY4SWA=; b=W0t+GGZLpJSe+W+elNQpUoWIbPCyfyicFEImH4QPyuhWou6EHtr+sCVAf9aj+zf35K +oEujffw6C6WHlfO+XMA== Received: by 10.42.244.133 with SMTP id lq5mr642525icb.29.1323383612054; Thu, 08 Dec 2011 14:33:32 -0800 (PST) Received: by 10.42.244.133 with SMTP id lq5mr642474icb.29.1323383611694; Thu, 08 Dec 2011 14:33:31 -0800 (PST) Received: from [2620:0:1008:1201:be30:5bff:fed8:5e64] ([2620:0:1008:1201:be30:5bff:fed8:5e64]) by mx.google.com with ESMTPS id z22sm1988056ibg.5.2011.12.08.14.33.30 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 08 Dec 2011 14:33:31 -0800 (PST) Date: Thu, 8 Dec 2011 14:33:29 -0800 (PST) From: David Rientjes X-X-Sender: rientjes@chino.kir.corp.google.com To: Subrata Modak , Benjamin Herrenschmidt , Paul Mackerras Subject: [patch] powerpc, mm: fix section mismatch for mark_reserved_regions_for_nid In-Reply-To: <1323371433.23534.8.camel@subratamodak.linux.ibm.com> Message-ID: References: <1323371433.23534.8.camel@subratamodak.linux.ibm.com> User-Agent: Alpine 2.00 (DEB 1167 2008-08-23) MIME-Version: 1.0 Cc: Mark Wizner , Naveed , linux-kernel@vger.kernel.org, Manas k Nayak , Pavaman , Anton Blanchard , Vishu , linuxppc-dev@lists.ozlabs.org, "divya.vikas" X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org On Fri, 9 Dec 2011, Subrata Modak wrote: > WARNING: vmlinux.o(.text+0x4c760): Section mismatch in reference from > the function .mark_reserved_regions_for_nid() to the > function .meminit.text:.early_pfn_to_nid() > The function .mark_reserved_regions_for_nid() references > the function __meminit .early_pfn_to_nid(). > This is often because .mark_reserved_regions_for_nid lacks a __meminit > annotation or the annotation of .early_pfn_to_nid is wrong. > > WARNING: vmlinux.o(.text+0x4c780): Section mismatch in reference from > the function .mark_reserved_regions_for_nid() to the > function .init.text:.work_with_active_regions() > The function .mark_reserved_regions_for_nid() references > the function __init .work_with_active_regions(). > This is often because .mark_reserved_regions_for_nid lacks a __init > annotation or the annotation of .work_with_active_regions is wrong. > > WARNING: vmlinux.o(.text+0x4c7d4): Section mismatch in reference from > the function .mark_reserved_regions_for_nid() to the > function .meminit.text:.early_pfn_to_nid() > The function .mark_reserved_regions_for_nid() references > the function __meminit .early_pfn_to_nid(). > This is often because .mark_reserved_regions_for_nid lacks a __meminit > annotation or the annotation of .early_pfn_to_nid is wrong. > > WARNING: vmlinux.o(.text+0x4c7f0): Section mismatch in reference from > the function .mark_reserved_regions_for_nid() to the > function .init.text:.work_with_active_regions() > The function .mark_reserved_regions_for_nid() references > the function __init .work_with_active_regions(). > This is often because .mark_reserved_regions_for_nid lacks a __init > annotation or the annotation of .work_with_active_regions is wrong. > > WARNING: vmlinux.o(.text+0x4c828): Section mismatch in reference from > the function .mark_reserved_regions_for_nid() to the > function .init.text:.reserve_bootmem_node() > The function .mark_reserved_regions_for_nid() references > the function __init .reserve_bootmem_node(). > This is often because .mark_reserved_regions_for_nid lacks a __init > annotation or the annotation of .reserve_bootmem_node is wrong. > Wow, lots of ibm folks on the cc :) I can only talk about the mm related section mismatches, but these five can easily be solved with the following. powerpc, mm: fix section mismatch for mark_reserved_regions_for_nid mark_reserved_regions_for_nid() is only called from do_init_bootmem(), which is in .init.text, so it must be in the same section to avoid a section mismatch warning. Reported-by: Subrata Modak Signed-off-by: David Rientjes --- arch/powerpc/mm/numa.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/arch/powerpc/mm/numa.c b/arch/powerpc/mm/numa.c --- a/arch/powerpc/mm/numa.c +++ b/arch/powerpc/mm/numa.c @@ -969,7 +969,7 @@ static struct notifier_block __cpuinitdata ppc64_numa_nb = { .priority = 1 /* Must run before sched domains notifier. */ }; -static void mark_reserved_regions_for_nid(int nid) +static void __init mark_reserved_regions_for_nid(int nid) { struct pglist_data *node = NODE_DATA(nid); struct memblock_region *reg;