lkml.org 
[lkml]   [2023]   [Jul]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] kconfig: tell the kconfig symbol of the restart reason
Date
When running 'make oldconfig' or 'make olddefconfig' without waiting
for prompts, it can be useful to know the restart reason so that it
can be fixed manually.

This is usually when the prompt value is a number or a string,
i.e., something other than y/m/n.

Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Cc: Masahiro Yamada <masahiroy@kernel.org>
Cc: linux-kbuild@vger.kernel.org
---
Can the test for sym->name be omitted?

scripts/kconfig/conf.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)

diff -- a/scripts/kconfig/conf.c b/scripts/kconfig/conf.c
--- a/scripts/kconfig/conf.c
+++ b/scripts/kconfig/conf.c
@@ -652,8 +652,12 @@ static void check_conf(struct menu *menu
printf("-----\n");
break;
default:
- if (!conf_cnt++)
- printf("*\n* Restart config...\n*\n");
+ if (!conf_cnt++) {
+ printf("*\n* Restart config...\n");
+ if (sym->name)
+ printf("* due to symbol: %s\n", sym->name);
+ printf("*\n");
+ }
rootEntry = menu_get_parent_menu(menu);
conf(rootEntry);
break;
\
 
 \ /
  Last update: 2023-07-04 07:53    [W:0.031 / U:0.164 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site