Skip to content

Commit faaae2a

Browse files
committed
Re-enable CONFIG_MODVERSIONS in a slightly weaker form
This enables CONFIG_MODVERSIONS again, but allows for missing symbol CRC information in order to work around the issue that newer binutils versions seem to occasionally drop the CRC on the floor. binutils 2.26 seems to work fine, while binutils 2.27 seems to break MODVERSIONS of symbols that have been defined in assembler files. [ We've had random missing CRC's before - it may be an old problem that just is now reliably triggered with the weak asm symbols and a new version of binutils ] Some day I really do want to remove MODVERSIONS entirely. Sadly, today does not appear to be that day: Debian people apparently do want the option to enable MODVERSIONS to make it easier to have external modules across kernel versions, and this seems to be a fairly minimal fix for the annoying problem. Cc: Ben Hutchings <ben@decadent.org.uk> Acked-by: Michal Marek <mmarek@suse.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent 22d3d4f commit faaae2a

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

‎init/Kconfig‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1945,7 +1945,6 @@ config MODULE_FORCE_UNLOAD
19451945

19461946
config MODVERSIONS
19471947
bool "Module versioning support"
1948-
depends on BROKEN
19491948
help
19501949
Usually, you have to use modules compiled with your kernel.
19511950
Saying Y here makes it sometimes possible to use modules

‎kernel/module.c‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1301,8 +1301,9 @@ static int check_version(Elf_Shdr *sechdrs,
13011301
goto bad_version;
13021302
}
13031303

1304-
pr_warn("%s: no symbol version for %s\n", mod->name, symname);
1305-
return 0;
1304+
/* Broken toolchain. Warn once, then let it go.. */
1305+
pr_warn_once("%s: no symbol version for %s\n", mod->name, symname);
1306+
return 1;
13061307

13071308
bad_version:
13081309
pr_warn("%s: disagrees about version of symbol %s\n",

0 commit comments

Comments
 (0)