Skip to content

Commit 11097a0

Browse files
modules: do not depend on kconfig to set 'modules' option to symbol MODULES
Currently, the MODULES symbol is special-cased in different places in the kconfig language. For example, if no symbol is defined to enable tristates, then kconfig looks up for a symbol named 'MODULES', and forces the 'modules' option onto that symbol. This causes problems as such: - since MODULES is special-cased, reading the configuration with KCONFIG_ALLCONFIG set will forcibly set MODULES to be 'valid' (ie. it has a valid value), when no such value was previously set. So MODULES defaults to 'n' unless it is present in KCONFIG_ALLCONFIG - other third-party projects may decide that 'MODULES' plays a different role for them This has been exposed by cset #cfa98f2e: kconfig: do not override symbols already set and reported by Stephen in: http://marc.info/?l=linux-next&m=137592137915234&w=2 As suggested by Sam, we explicitly define the MODULES symbol to be the tristate-enabler. This will allow us to drop special-casing of MODULES in the kconfig language, later. (Note: this patch is not a fix to Stephen's issue, just a first step). Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: yann.morin.1998@free.fr Cc: Stephen Rothwell <sfr@canb.auug.org.au> Cc: Sam Ravnborg <sam@ravnborg.org> Cc: Michal Marek <mmarek@suse.cz> Cc: Kevin Hilman <khilman@linaro.org> Cc: sedat.dilek@gmail.com Cc: Theodore Ts'o <tytso@mit.edu>
1 parent 04b19b7 commit 11097a0

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

‎init/Kconfig‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1666,6 +1666,7 @@ config BASE_SMALL
16661666

16671667
menuconfig MODULES
16681668
bool "Enable loadable module support"
1669+
option modules
16691670
help
16701671
Kernel modules are small pieces of compiled code which can
16711672
be inserted in the running kernel, rather than being

0 commit comments

Comments
 (0)