public inbox for linux-kbuild@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/3] kconfig: remove unneeded variable in get_prompt_str()
@ 2022-11-13 10:59 Masahiro Yamada
  2022-11-13 10:59 ` [PATCH 2/3] kconfig: remove const qualifier from str_get() Masahiro Yamada
  2022-11-13 10:59 ` [PATCH 3/3] kconfig: remove redundant (void *) cast in search_conf() Masahiro Yamada
  0 siblings, 2 replies; 3+ messages in thread
From: Masahiro Yamada @ 2022-11-13 10:59 UTC (permalink / raw)
  To: linux-kbuild; +Cc: Masahiro Yamada, linux-kernel

The variable 'accessible' is redundant.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
---

 scripts/kconfig/menu.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/scripts/kconfig/menu.c b/scripts/kconfig/menu.c
index 109325f31bef..b90fff833588 100644
--- a/scripts/kconfig/menu.c
+++ b/scripts/kconfig/menu.c
@@ -724,10 +724,8 @@ static void get_prompt_str(struct gstr *r, struct property *prop,
 
 	menu = prop->menu;
 	for (i = 0; menu != &rootmenu && i < 8; menu = menu->parent) {
-		bool accessible = menu_is_visible(menu);
-
 		submenu[i++] = menu;
-		if (location == NULL && accessible)
+		if (location == NULL && menu_is_visible(menu))
 			location = menu;
 	}
 	if (head && location) {
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-11-13 11:00 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-13 10:59 [PATCH 1/3] kconfig: remove unneeded variable in get_prompt_str() Masahiro Yamada
2022-11-13 10:59 ` [PATCH 2/3] kconfig: remove const qualifier from str_get() Masahiro Yamada
2022-11-13 10:59 ` [PATCH 3/3] kconfig: remove redundant (void *) cast in search_conf() Masahiro Yamada

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox