diff options
Diffstat (limited to 'extras/recipes-kernel/linux/linux-omap/linus/0029-kconfig-fix-undesirable-side-effect-of-adding-visibl.patch')
-rw-r--r-- | extras/recipes-kernel/linux/linux-omap/linus/0029-kconfig-fix-undesirable-side-effect-of-adding-visibl.patch | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/extras/recipes-kernel/linux/linux-omap/linus/0029-kconfig-fix-undesirable-side-effect-of-adding-visibl.patch b/extras/recipes-kernel/linux/linux-omap/linus/0029-kconfig-fix-undesirable-side-effect-of-adding-visibl.patch new file mode 100644 index 00000000..c1af0112 --- /dev/null +++ b/extras/recipes-kernel/linux/linux-omap/linus/0029-kconfig-fix-undesirable-side-effect-of-adding-visibl.patch | |||
@@ -0,0 +1,49 @@ | |||
1 | From 38f5b0c391281eded0e6e5b2bc75a28ae72d0abe Mon Sep 17 00:00:00 2001 | ||
2 | From: Jan Beulich <JBeulich@novell.com> | ||
3 | Date: Thu, 9 Dec 2010 08:11:38 +0000 | ||
4 | Subject: [PATCH 29/65] kconfig: fix undesirable side effect of adding "visible" menu attribute | ||
5 | |||
6 | This lead to non-selected, non-user-selectable options to be written | ||
7 | out to .config. This is not only pointless, but also preventing the | ||
8 | user to be prompted should any of those options eventually become | ||
9 | visible (e.g. by de-selecting the *_AUTO options the "visible" | ||
10 | attribute was added for. | ||
11 | |||
12 | Furthermore it is quite logical for the "visible" attribute of a menu | ||
13 | to control the visibility of all contained prompts, which is what the | ||
14 | patch does. | ||
15 | |||
16 | Signed-off-by: Jan Beulich <jbeulich@novell.com> | ||
17 | Signed-off-by: Michal Marek <mmarek@suse.cz> | ||
18 | --- | ||
19 | scripts/kconfig/menu.c | 14 ++++++++++++++ | ||
20 | 1 files changed, 14 insertions(+), 0 deletions(-) | ||
21 | |||
22 | diff --git a/scripts/kconfig/menu.c b/scripts/kconfig/menu.c | ||
23 | index b9d9aa1..5f77dcb 100644 | ||
24 | --- a/scripts/kconfig/menu.c | ||
25 | +++ b/scripts/kconfig/menu.c | ||
26 | @@ -140,6 +140,20 @@ struct property *menu_add_prop(enum prop_type type, char *prompt, struct expr *e | ||
27 | } | ||
28 | if (current_entry->prompt && current_entry != &rootmenu) | ||
29 | prop_warn(prop, "prompt redefined"); | ||
30 | + | ||
31 | + /* Apply all upper menus' visibilities to actual prompts. */ | ||
32 | + if(type == P_PROMPT) { | ||
33 | + struct menu *menu = current_entry; | ||
34 | + | ||
35 | + while ((menu = menu->parent) != NULL) { | ||
36 | + if (!menu->visibility) | ||
37 | + continue; | ||
38 | + prop->visible.expr | ||
39 | + = expr_alloc_and(prop->visible.expr, | ||
40 | + menu->visibility); | ||
41 | + } | ||
42 | + } | ||
43 | + | ||
44 | current_entry->prompt = prop; | ||
45 | } | ||
46 | prop->text = prompt; | ||
47 | -- | ||
48 | 1.6.6.1 | ||
49 | |||