diff options
author | Masahiro Yamada <masahiroy@kernel.org> | 2021-10-01 08:32:47 +0300 |
---|---|---|
committer | Masahiro Yamada <masahiroy@kernel.org> | 2021-10-11 17:13:23 +0300 |
commit | 51d792cb5de87fa8777b4769a33c302e4ad0580a (patch) | |
tree | 4c57f4a5e75c60ec6117621259f205cec2c48cc2 /scripts/kconfig/confdata.c | |
parent | 6ce45a91a9826532dde7c89cd2d6388c0bcb0cf7 (diff) | |
download | linux-51d792cb5de87fa8777b4769a33c302e4ad0580a.tar.xz |
kconfig: refactor listnewconfig code
We can reuse __print_symbol() helper to print symbols for listnewconfig.
Only the difference is the format for "n" symbols.
This prints "CONFIG_FOO=n" instead of "# CONFIG_FOO is not set".
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Diffstat (limited to 'scripts/kconfig/confdata.c')
-rw-r--r-- | scripts/kconfig/confdata.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/scripts/kconfig/confdata.c b/scripts/kconfig/confdata.c index 4e3fd194231b..f17a2a9562ee 100644 --- a/scripts/kconfig/confdata.c +++ b/scripts/kconfig/confdata.c @@ -667,6 +667,11 @@ static void print_symbol_for_autoconf(FILE *fp, struct symbol *sym) __print_symbol(fp, sym, OUTPUT_N_NONE, true); } +void print_symbol_for_listconfig(struct symbol *sym) +{ + __print_symbol(stdout, sym, OUTPUT_N, true); +} + static void print_symbol_for_c(FILE *fp, struct symbol *sym) { const char *val; |