LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
To: Sam Ravnborg <sam@ravnborg.org>
Cc: linux-kbuild <linux-kbuild@vger.kernel.org>,
	LKML <linux-kernel@vger.kernel.org>,
	Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [REVIEW for merge] kbuild updates including silence of section mismatch check
Date: Tue, 5 Feb 2008 11:38:49 +0100 (CET)	[thread overview]
Message-ID: <Pine.LNX.4.64.0802051116410.1588@vixen.sonytel.be> (raw)
In-Reply-To: <20080202203503.GA26415@uranus.ravnborg.org>

[-- Attachment #1: Type: TEXT/PLAIN, Size: 2846 bytes --]

On Sat, 2 Feb 2008, Sam Ravnborg wrote:
> The most visible change is that I have made all the section mismatch
> go away and in the end of the build modpost report the number
> of section mismatch warnings and how to see detail.
> 
> The typical output is now:
> 
> modpost: Found 35 section mismatch(es).
> To see full details build your kernel with:
> 'make CONFIG_DEBUG_SECTION_MISMATCH=y'

Can we get a `warning' string literal in that message, so I notice it when
grepping for compiler warnings?

... Ah, there already exists a warn() routine, so let's use it.

Subject: modpost: Use warn() for announcing section mismatches

From: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>

modpost: Use warn() for announcing section mismatches, for easy grepping for
warnings in build logs.

Also change an existing call from fprintf() to warn() while we're at it.

Signed-off-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
---
 scripts/mod/modpost.c |   16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

--- a/scripts/mod/modpost.c
+++ b/scripts/mod/modpost.c
@@ -1129,10 +1129,10 @@ static void report_sec_mismatch(const ch
 	if (!sec_mismatch_verbose)
 		return;
 
-	fprintf(stderr, "WARNING: %s(%s+0x%llx): Section mismatch in"
-	                " reference from the %s %s%s to the %s %s:%s%s\n",
-                        modname, fromsec, fromaddr, from, fromsym, from_p,
-	                to, tosec, tosym, to_p);
+	warn("%s(%s+0x%llx): Section mismatch in reference from the %s %s%s "
+	     "to the %s %s:%s%s\n",
+	     modname, fromsec, fromaddr, from, fromsym, from_p, to, tosec,
+	     tosym, to_p);
 
 	switch (mismatch) {
 	case TEXT_TO_INIT:
@@ -1938,10 +1938,10 @@ int main(int argc, char **argv)
 	if (dump_write)
 		write_dump(dump_write);
 	if (sec_mismatch_count && !sec_mismatch_verbose)
-		fprintf(stderr, "modpost: Found %d section mismatch(es).\n"
-		        "To see full details build your kernel with:\n"
-		        "'make CONFIG_DEBUG_SECTION_MISMATCH=y'\n",
-		        sec_mismatch_count);
+		warn("modpost: Found %d section mismatch(es).\n"
+		     "To see full details build your kernel with:\n"
+		     "'make CONFIG_DEBUG_SECTION_MISMATCH=y'\n",
+		     sec_mismatch_count);
 
 	return err;
 }

With kind regards,

Geert Uytterhoeven
Software Architect

Sony Network and Software Technology Center Europe
The Corporate Village · Da Vincilaan 7-D1 · B-1935 Zaventem · Belgium

Phone:    +32 (0)2 700 8453
Fax:      +32 (0)2 700 8622
E-mail:   Geert.Uytterhoeven@sonycom.com
Internet: http://www.sony-europe.com/

Sony Network and Software Technology Center Europe
A division of Sony Service Centre (Europe) N.V.
Registered office: Technologielaan 7 · B-1840 Londerzeel · Belgium
VAT BE 0413.825.160 · RPR Brussels
Fortis Bank Zaventem · Swift GEBABEBB08A · IBAN BE39001382358619

  parent reply	other threads:[~2008-02-05 10:39 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-02-02 20:35 Sam Ravnborg
2008-02-02 21:25 ` Frans Pop
2008-02-02 21:30   ` Sam Ravnborg
2008-02-03  3:30     ` Bryan Wu
2008-02-03  6:13     ` [PATCH try#2 ] kbuild: add svn revision information to setlocalversion Bryan Wu
2008-02-03 10:04       ` Sam Ravnborg
2008-02-02 22:37 ` [Additional PATCH] kbuild: do not warn about __*init/__*exit symbols being exported Sam Ravnborg
2008-02-05 10:38 ` Geert Uytterhoeven [this message]
2008-02-06 20:58   ` [REVIEW for merge] kbuild updates including silence of section mismatch check 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=Pine.LNX.4.64.0802051116410.1588@vixen.sonytel.be \
    --to=geert.uytterhoeven@sonycom.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sam@ravnborg.org \
    --subject='Re: [REVIEW for merge] kbuild updates including silence of section mismatch check' \
    /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

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).