From: Yinghai Lu <yinghai@kernel.org>
To: "H. Peter Anvin" <hpa@zytor.com>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>,
Thomas Gleixner <tglx@linutronix.de>, Ingo Molnar <mingo@elte.hu>,
Peter Zijlstra <peterz@infradead.org>,
linux-next@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: linux-next: build warning after merge of the final tree (tip tree related)
Date: Mon, 11 Oct 2010 12:34:09 -0700 [thread overview]
Message-ID: <4CB366B1.40405@kernel.org> (raw)
In-Reply-To: <4CB35EC1.5040909@zytor.com>
On 10/11/2010 12:00 PM, H. Peter Anvin wrote:
> On 10/11/2010 10:09 AM, Yinghai Lu wrote:
>>
>> make all functions in memblock.c without __init to carry __init_memblock.
>>
>>
>> -static phys_addr_t __init memblock_find_region(phys_addr_t start, phys_addr_t end,
>> +static phys_addr_t __init_memblock memblock_find_region(phys_addr_t start, phys_addr_t end,
>> phys_addr_t size, phys_addr_t align)
>>
>> -static int memblock_search(struct memblock_type *type, phys_addr_t addr)
>> +static int __init_memblock memblock_search(struct memblock_type *type, phys_addr_t addr)
>>
>
> Your patch description doesn't match what your patch does. Please write
> a correct description.
please check
[PATCH -v2] x86: Fix section mismatch with memblock_find_region()
Stephen found
WARNING: mm/built-in.o(.text+0x25ab8): Section mismatch in reference from the function memblock_find_base() to the function .init.text:memblock_find_region()
The function memblock_find_base() references
the function __init memblock_find_region().
This is often because memblock_find_base lacks a __init
annotation or the annotation of memblock_find_region is wrong.
So let memblock_find_region() to use __init_memblock insteaf of __init directly.
Also make left function that doesn't have __init* to carry __init_memblock.
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Yinghai Lu <yinghai@kernel.org>
---
mm/memblock.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
Index: linux-2.6/mm/memblock.c
===================================================================
--- linux-2.6.orig/mm/memblock.c
+++ linux-2.6/mm/memblock.c
@@ -99,7 +99,7 @@ long __init_memblock memblock_overlaps_r
* are top-down.
*/
-static phys_addr_t __init memblock_find_region(phys_addr_t start, phys_addr_t end,
+static phys_addr_t __init_memblock memblock_find_region(phys_addr_t start, phys_addr_t end,
phys_addr_t size, phys_addr_t align)
{
phys_addr_t base, res_base;
@@ -653,7 +653,7 @@ void __init memblock_enforce_memory_limi
}
}
-static int memblock_search(struct memblock_type *type, phys_addr_t addr)
+static int __init_memblock memblock_search(struct memblock_type *type, phys_addr_t addr)
{
unsigned int left = 0, right = type->cnt;
next prev parent reply other threads:[~2010-10-11 19:35 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-11 5:04 linux-next: build warning after merge of the final tree (tip tree related) Stephen Rothwell
2010-10-11 17:09 ` Yinghai Lu
2010-10-11 19:00 ` H. Peter Anvin
2010-10-11 19:34 ` Yinghai Lu [this message]
-- strict thread matches above, loose matches on Subject: below --
2013-03-12 4:42 Stephen Rothwell
2013-03-12 5:16 ` Li Zefan
2013-03-12 5:45 ` Stephen Rothwell
2010-04-15 4:36 Stephen Rothwell
2010-04-15 5:29 ` Mike Galbraith
2010-04-15 6:17 ` Stephen Rothwell
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=4CB366B1.40405@kernel.org \
--to=yinghai@kernel.org \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-next@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=peterz@infradead.org \
--cc=sfr@canb.auug.org.au \
--cc=tglx@linutronix.de \
/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;
as well as URLs for NNTP newsgroup(s).