From: Paul Gortmaker Date: Thu, 12 Apr 2012 23:46:33 +0000 (-0400) Subject: Revert "kconfig: fix __enabled_ macros definition for invisible and un-selected symbols" X-Git-Tag: 1.9.7~23 X-Git-Url: https://jxself.org/git/?a=commitdiff_plain;h=da07930fac078b9a116196076dff1a5ddc85f0aa;p=carl9170fw.git Revert "kconfig: fix __enabled_ macros definition for invisible and un-selected symbols" Dumping two lines into autoconf.h for all existing Kconfig options results in a giant file (~16k lines) we have to process each time we compile something. We've weaned IS_ENABLED() and similar off of requiring the __enabled_ definitions so now we can revert the change which caused all the extra lines. Signed-off-by: Paul Gortmaker Signed-off-by: Linus Torvalds Signed-off-by: Christian Lamparter --- diff --git a/config/confdata.c b/config/confdata.c index d45c37e..41a59bb 100644 --- a/config/confdata.c +++ b/config/confdata.c @@ -535,6 +535,17 @@ header_print_symbol(FILE *fp, struct symbol *sym, const char *value, void *arg) fprintf(fp, "#define %s%s%s 1\n", CONFIG_, sym->name, suffix); } + /* + * Generate the __enabled_CONFIG_* and + * __enabled_CONFIG_*_MODULE macros for use by the + * IS_{ENABLED,BUILTIN,MODULE} macros. The _MODULE variant is + * generated even for booleans so that the IS_ENABLED() macro + * works. + */ + fprintf(fp, "#define __enabled_" CONFIG_ "%s %d\n", + sym->name, (*value == 'y')); + fprintf(fp, "#define __enabled_" CONFIG_ "%s_MODULE %d\n", + sym->name, (*value == 'm')); break; } case S_HEX: {