From: Kumar Gala <galak@kernel.crashing.org>
To: Sam Ravnborg <sam@ravnborg.org>
Cc: Li Yang <leoli@freescale.com>,
Linus <torvalds@linux-foundation.org>,
Andrew Morton <akpm@osdl.org>,
Linux Kernel <linux-kernel@vger.kernel.org>,
linuxppc-dev@ozlabs.org
Subject: Re: [PATCH 1/2] kbuild: Add "Section mismatch" warning whitelist for powerpc
Date: Mon, 14 May 2007 08:56:52 -0500 [thread overview]
Message-ID: <3DF58590-DFD9-4665-8C47-33F407AAD1E7@kernel.crashing.org> (raw)
In-Reply-To: <20070514110636.GB10143@uranus.ravnborg.org>
On May 14, 2007, at 6:06 AM, Sam Ravnborg wrote:
> On Mon, May 14, 2007 at 06:53:32PM +0800, Li Yang wrote:
>> This patch fixes the following "Section mismatch" warnings when
>> build powerpc platforms.
>>
>> -------------
>> WARNING: arch/powerpc/mm/built-in.o - Section mismatch: reference to
>> .init.text:early_get_page from .text between
>> 'pte_alloc_one_kernel' (at
>> offset 0xc68) and 'pte_alloc_one'
>> WARNING: mm/built-in.o - Section mismatch: reference to
>> .init.text:set_up_list3s from .text between
>> 'kmem_cache_create' (at offset
>> 0x20300) and 'cache_reap'
>> -------------
This warnings should be handled by __init_refok instead.
- k
>> Massive warnings represented by:
>> -------------
>> WARNING: arch/powerpc/kernel/built-in.o - Section mismatch:
>> reference to
>> .init.data:.got2 from prom_entry (offset 0x0)
>> WARNING: arch/powerpc/platforms/built-in.o - Section mismatch:
>> reference to
>> .init.text:mpc8313_rdb_probe from .machine.desc after
>> 'mach_mpc8313_rdb'
>> (at offset 0x4)
>> -------------
>>
>> Signed-off-by: Li Yang <leoli@freescale.com>
> Acked-by: Sam Ravnborg <sam@ravnborg.org>
>> ---
>> scripts/mod/modpost.c | 16 ++++++++++++----
>> 1 files changed, 12 insertions(+), 4 deletions(-)
>>
>> diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c
>> index c89cb71..aa3a881 100644
>> --- a/scripts/mod/modpost.c
>> +++ b/scripts/mod/modpost.c
>> @@ -649,9 +649,10 @@ static int strrcmp(const char *s, const char
>> *sub)
>> * tosec = .init.text
>> *
>> * Pattern 10:
>> - * ia64 has machvec table for each platform. It is mixture of
>> function
>> - * pointer of .init.text and .text.
>> - * fromsec = .machvec
>> + * ia64 has machvec table and powerpc has machine desc table for
>> each
>> + * platform. It is mixture of function pointer of .init.text
>> and .text.
>> + * fromsec = .machvec | .machine.desc
>> + *
>> **/
>> static int secref_whitelist(const char *modname, const char *tosec,
>> const char *fromsec, const char *atsym,
>> @@ -681,6 +682,8 @@ static int secref_whitelist(const char
>> *modname, const
>> char *tosec,
>> const char *pat4sym[] = {
>> "sparse_index_alloc",
>> "zone_wait_table_init",
>> + "pte_alloc_one_kernel",
>> + "kmem_cache_create",
>> NULL
>> };
>>
>> @@ -750,7 +753,8 @@ static int secref_whitelist(const char
>> *modname, const
>> char *tosec,
>> return 1;
>>
>> /* Check for pattern 10 */
>> - if (strcmp(fromsec, ".machvec") == 0)
>> + if ((strcmp(fromsec, ".machvec") == 0) ||
>> + (strcmp(fromsec, ".machine.desc") == 0))
>> return 1;
>>
>> return 0;
>> @@ -883,6 +887,10 @@ static void warn_sec_mismatch(const char
>> *modname,
>> const char *fromsec,
>> secref_whitelist(modname, secname, fromsec,
>> elf->strtab + before->st_name, refsymname))
>> return;
>> + /* fromsec whitelist - without a valid 'before' */
>> + /* powerpc has a GOT table in .got2 section */
>> + if (strcmp(fromsec, ".got2") == 0)
>> + return;
>>
>> if (before && after) {
>> warn("%s - Section mismatch: reference to %s:%s from %s "
>>
> -
> 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/
next prev parent reply other threads:[~2007-05-14 13:58 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-14 10:53 Li Yang
2007-05-14 11:06 ` Sam Ravnborg
2007-05-14 13:56 ` Kumar Gala [this message]
2007-05-14 19:30 ` Andrew Morton
2007-05-14 20:10 ` Kumar Gala
2007-05-14 21:13 ` Sam Ravnborg
2007-05-15 0:17 ` Satyam Sharma
2007-05-15 9:22 ` Li Yang-r58472
2007-05-15 10:03 ` Satyam Sharma
2007-05-15 10:56 ` Stephen Rothwell
2007-05-15 9:36 ` Li Yang-r58472
2007-05-15 19:29 ` Sam Ravnborg
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=3DF58590-DFD9-4665-8C47-33F407AAD1E7@kernel.crashing.org \
--to=galak@kernel.crashing.org \
--cc=akpm@osdl.org \
--cc=leoli@freescale.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@ozlabs.org \
--cc=sam@ravnborg.org \
--cc=torvalds@linux-foundation.org \
/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
Powered by JetHome