diff options
author | Yann E. MORIN <yann.morin.1998@free.fr> | 2013-09-03 17:07:18 +0200 |
---|---|---|
committer | Michal Marek <mmarek@suse.cz> | 2013-09-05 11:09:17 +0200 |
commit | 6902dccfda005fa4c42410fa064fdd331ab42479 (patch) | |
tree | 48b9df40035a8bf414350ed84c6bcb4438e4ace0 /scripts/kconfig/menu.c | |
parent | c8272faf5e3f0f97f5cd15af69e3a515efbe212d (diff) | |
download | linux-6902dccfda005fa4c42410fa064fdd331ab42479.tar.bz2 |
kconfig: do not special-case 'MODULES' symbol
Currently, the 'MODULES' symbol is hard-coded to be the default symbol
that enables/disables tristates, if no other symbol was declared with
'option modules'.
While this used to be needed for the Linux kernel, we now have an
explicit 'option modules' attached to the 'MODULES' symbol (since
cset 11097a036), so we no longer need to special-case it in the
kconfig code.
Furthermore, kconfig is extensively used out of the Linux kernel, and
other projects may have another meaning for a symbol named 'MODULES'.
This patch changes the way we enable/disable tristates: if a symbol was
found with 'option modules' attached to it, then that symbol controls
enabling tristates. Otherwise, tristates are disabled, even if a symbol
named 'MODULES' exists.
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Michal Marek <mmarek@suse.cz>
Diffstat (limited to 'scripts/kconfig/menu.c')
-rw-r--r-- | scripts/kconfig/menu.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/scripts/kconfig/menu.c b/scripts/kconfig/menu.c index 7e233a6ca64e..3a9c67493260 100644 --- a/scripts/kconfig/menu.c +++ b/scripts/kconfig/menu.c @@ -197,12 +197,9 @@ void menu_add_symbol(enum prop_type type, struct symbol *sym, struct expr *dep) void menu_add_option(int token, char *arg) { - struct property *prop; - switch (token) { case T_OPT_MODULES: - prop = prop_alloc(P_DEFAULT, modules_sym); - prop->expr = expr_alloc_symbol(current_entry->sym); + modules_sym = current_entry->sym; break; case T_OPT_DEFCONFIG_LIST: if (!sym_defconfig_list) |