Messages in this thread Patch in this message |  | | Date | Mon, 19 May 2003 23:15:14 +0200 (CEST) | From | Roman Zippel <> | Subject | Re: 2.5.69-bk1[23] kconfig loop |
| |
Hi,
On Mon, 19 May 2003, Adam J. Richter wrote:
> I expect there is no input that is supposed to cause > "make oldconfig" to go into an infinite loop, so this must at > least be a kconfig bug.
Yes, it is, conf should not restart the configuration if the symbol isn't changeable. The patch below fixes this and also fixes another possible problem with menuconfig.
bye, Roman
--- linux-2.5.69-bk13/scripts/kconfig/conf.c 16 Dec 2002 19:40:13 -0000 +++ linux-2.5.69-bk13/scripts/kconfig/conf.c 19 May 2003 20:36:28 -0000 @@ -456,29 +456,17 @@ static void check_conf(struct menu *menu return; sym = menu->sym; - if (!sym) - goto conf_childs; - - if (sym_is_choice(sym)) { - if (!sym_has_value(sym)) { + if (sym) { + if (sym_is_changable(sym) && !sym_has_value(sym)) { if (!conf_cnt++) printf("*\n* Restart config...\n*\n"); rootEntry = menu_get_parent_menu(menu); conf(rootEntry); } - if (sym_get_tristate_value(sym) != mod) + if (sym_is_choice(sym) && sym_get_tristate_value(sym) != mod) return; - goto conf_childs; - } - - if (!sym_has_value(sym)) { - if (!conf_cnt++) - printf("*\n* Restart config...\n*\n"); - rootEntry = menu_get_parent_menu(menu); - conf(rootEntry); } -conf_childs: for (child = menu->list; child; child = child->next) check_conf(child); } --- linux-2.5.69-bk13/scripts/kconfig/menu.c 17 Mar 2003 23:01:29 -0000 +++ linux-2.5.69-bk13/scripts/kconfig/menu.c 18 May 2003 22:27:39 -0000 @@ -283,8 +283,7 @@ struct menu *menu_get_parent_menu(struct { enum prop_type type; - while (menu != &rootmenu) { - menu = menu->parent; + for (; menu != &rootmenu; menu = menu->parent) { type = menu->prompt ? menu->prompt->type : 0; if (type == P_MENU || type == P_ROOTMENU) break;
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
|  |