summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorMasahiro Yamada <masahiroy@kernel.org>2024-04-21 14:13:02 +0300
committerMasahiro Yamada <masahiroy@kernel.org>2024-05-02 13:48:26 +0300
commitc2af3d03c51289629edaadf118445fd29933c456 (patch)
tree10af722f9702f28869ba179a30872206daecc94d /scripts
parent03c4ecaa5c76640f1993733be1bded18e0c074d5 (diff)
downloadlinux-c2af3d03c51289629edaadf118445fd29933c456.tar.xz
kconfig: remove unneeded if-conditional in conf_choice()
All symbols except choices have a name. child->sym->name never becomes NULL inside choice blocks. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/kconfig/conf.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/scripts/kconfig/conf.c b/scripts/kconfig/conf.c
index 965bb40c50e5..0156ca13f949 100644
--- a/scripts/kconfig/conf.c
+++ b/scripts/kconfig/conf.c
@@ -497,9 +497,8 @@ static int conf_choice(struct menu *menu)
printf("%*c", indent, '>');
} else
printf("%*c", indent, ' ');
- printf(" %d. %s", cnt, menu_get_prompt(child));
- if (child->sym->name)
- printf(" (%s)", child->sym->name);
+ printf(" %d. %s (%s)", cnt, menu_get_prompt(child),
+ child->sym->name);
if (!sym_has_value(child->sym))
printf(" (NEW)");
printf("\n");