diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-01-02 21:37:19 +0300 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-01-02 21:37:19 +0300 |
commit | d864b7b4d69d2fd5a3f129d27ad0bb4fc81cc32b (patch) | |
tree | b1a0e05af5d691d8098614a40b57576716761f1d /scripts | |
parent | 3643e0e87c13c670a0fdcd0c34401b38b36ff021 (diff) | |
parent | 7ad1227818f09242cfe9bf1845fd24211f5f99bd (diff) | |
download | linux-d864b7b4d69d2fd5a3f129d27ad0bb4fc81cc32b.tar.xz |
Merge branch 'rc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild-2.6
* 'rc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild-2.6:
kconfig: fix undesirable side effect of adding "visible" menu attribute
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/kconfig/menu.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/scripts/kconfig/menu.c b/scripts/kconfig/menu.c index b9d9aa18e6d6..5f77dcb8977e 100644 --- a/scripts/kconfig/menu.c +++ b/scripts/kconfig/menu.c @@ -140,6 +140,20 @@ struct property *menu_add_prop(enum prop_type type, char *prompt, struct expr *e } if (current_entry->prompt && current_entry != &rootmenu) prop_warn(prop, "prompt redefined"); + + /* Apply all upper menus' visibilities to actual prompts. */ + if(type == P_PROMPT) { + struct menu *menu = current_entry; + + while ((menu = menu->parent) != NULL) { + if (!menu->visibility) + continue; + prop->visible.expr + = expr_alloc_and(prop->visible.expr, + menu->visibility); + } + } + current_entry->prompt = prop; } prop->text = prompt; |