Преглед изворни кода

kconfig: Clarify menu and 'if' dependency propagation

It is not obvious that the last two cases refer to menus and ifs,
respectively, in the conditional that sets 'parentdep'.

Automatic submenu creation is done later, so the parent can't be a
symbol here.

No functional changes. Only comments added.

Signed-off-by: Ulf Magnusson <ulfalizer@gmail.com>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Ulf Magnusson пре 8 година
родитељ
комит
b53688014e
1 измењених фајлова са 2 додато и 0 уклоњено
  1. 2 0
      scripts/kconfig/menu.c

+ 2 - 0
scripts/kconfig/menu.c

@@ -332,8 +332,10 @@ void menu_finalize(struct menu *parent)
 			 */
 			 */
 			parentdep = expr_alloc_symbol(sym);
 			parentdep = expr_alloc_symbol(sym);
 		} else if (parent->prompt)
 		} else if (parent->prompt)
+			/* Menu node for 'menu' */
 			parentdep = parent->prompt->visible.expr;
 			parentdep = parent->prompt->visible.expr;
 		else
 		else
+			/* Menu node for 'if' */
 			parentdep = parent->dep;
 			parentdep = parent->dep;
 
 
 		/* For each child menu node... */
 		/* For each child menu node... */