diff options
author | Sam Ravnborg <sam@ravnborg.org> | 2008-02-02 18:57:18 +0100 |
---|---|---|
committer | Sam Ravnborg <sam@ravnborg.org> | 2008-02-03 08:58:07 +0100 |
commit | e5f95c8b7700a7bf1c2d24eedc677954d9aa0285 (patch) | |
tree | cc7b0105a6acf863e508f51dc3450df080f0e0c9 | |
parent | 9135f1901ee6449dfe338adf6e40e9c2025b8150 (diff) | |
download | linux-e5f95c8b7700a7bf1c2d24eedc677954d9aa0285.tar.gz linux-e5f95c8b7700a7bf1c2d24eedc677954d9aa0285.tar.bz2 linux-e5f95c8b7700a7bf1c2d24eedc677954d9aa0285.zip |
kbuild: print only total number of section mismatces found
We have too many section mismatches detected at the moment.
So silence modpost and prevent the option from being
set in a typical allyesconfig build.
Tell the user how to see all the deteils in the summary
message from modpost.
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
-rw-r--r-- | lib/Kconfig.debug | 2 | ||||
-rw-r--r-- | scripts/mod/modpost.c | 15 |
2 files changed, 8 insertions, 9 deletions
diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug index 0d8a5a4a789d..d090d7201086 100644 --- a/lib/Kconfig.debug +++ b/lib/Kconfig.debug @@ -81,7 +81,7 @@ config HEADERS_CHECK config DEBUG_SECTION_MISMATCH bool "Enable full Section mismatch analysis" - default n + depends on UNDEFINED help The section mismatch analysis checks if there are illegal references from one section to another section. diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c index f8efc93eb700..c2e918e2cef1 100644 --- a/scripts/mod/modpost.c +++ b/scripts/mod/modpost.c @@ -1125,15 +1125,15 @@ static void report_sec_mismatch(const char *modname, enum mismatch mismatch, to = to_is_func ? "function" : "variable"; to_p = to_is_func ? "()" : ""; + sec_mismatch_count++; + 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); - sec_mismatch_count++; - if (!sec_mismatch_verbose) - return; - switch (mismatch) { case TEXT_TO_INIT: fprintf(stderr, @@ -1939,10 +1939,9 @@ int main(int argc, char **argv) write_dump(dump_write); if (sec_mismatch_count && !sec_mismatch_verbose) fprintf(stderr, "modpost: Found %d section mismatch(es).\n" - "To see additional details select \"Enable full " - "Section mismatch analysis\"\n" - "in the Kernel Hacking menu " - "(CONFIG_SECTION_MISMATCH).\n", sec_mismatch_count); + "To see full details build your kernel with:\n" + "'make CONFIG_DEBUG_SECTION_MISMATCH=y'\n", + sec_mismatch_count); return err; } |