Pull request for branch yem-kconfig-for-next
Subsystems (4)
PATCH 1/8 menuconfig: Fix memory leak introduced by jump keys feature
In reply to Yann E. MORINFrom: Benjamin Poirier <[email protected]>
Fixes the memory leak of struct jump_key allocated in get_prompt_str()
--- scripts/kconfig/list.h | 13 +++++++++++++ scripts/kconfig/mconf.c | 3 +++ 2 files changed, 16 insertions(+)
scripts/kconfig/list.h +13 -0
@@ -51,6 +51,19 @@ struct list_head { pos = list_entry(pos->member.next, typeof(*pos), member))/** +* list_for_each_entry_safe - iterate over list of given type safe against removal of list entry +* @pos: the type * to use as a loop cursor. +* @n: another type * to use as temporary storage +* @head: the head for your list. +* @member: the name of the list_struct within the struct. +*/ +#define list_for_each_entry_safe (pos, n, head, member) \ + for (pos = list_entry((head)->next, typeof(*pos), member), \ + n = list_entry(pos->member.next, typeof(*pos), member); \ + &pos->member != (head); \ + pos = n, n = list_entry(n->member.next, typeof(*n), member)) + +/** * list_empty - tests whether a list is empty * @head: the list to test. */
scripts/kconfig/mconf.c +3 -0
@@ -389,6 +389,7 @@ again: .targets = targets, .keys = keys, }; +struct jump_key *pos, *tmp; res =get_relations_str (sym_arr, &head); dres = show_textbox_ext(_("Search Results"), (char *)
@@ -402,6 +403,8 @@ again: again = true; }str_free (&res); +list_for_each_entry_safe (pos, tmp, &head, entries) +free (pos); }while (again);free (sym_arr);str_free (&title);
Signature · 1 line
1.7.10.4
From: "Yann E. MORIN" <[email protected]>
Michal,
Here is the official pull-request for the kconfig-related changes I've gathered from the linux-kbuild list, and those I've locally accumulated, for inclusin in 3.10:
- memory leak fixed in mconf
- 3 randconfig fixes (randomising choices, setting tristates, already set symbols)
- randconfig improvements: seed, and probability skew
- navigation breadcrumbs in mconf
Changes v1 -> v2:
- restore the previous probabilities per default
- use different probabilities for booleans and tristates
- two new fixes for randconfig
- Cc: lkml this time
Regards,
Yann E. MORIN
----------------------------------------------------------------
The following changes since commit a45c7dfb942b6c198d5cd283f8dcee145241a017:
merge_config.sh: Avoid creating unnessary source softlinks (2013-04-10 10:55:22 +0200)
are available in the git repository at:
git://gitorious.org/linux-kconfig/linux-kconfig.git yem-kconfig-for-next
for you to fetch changes up to e43956e607692f9b1c710311e4a6591ffba1edf0:
kconfig: implement KCONFIG_PROBABILITY for randconfig (2013-04-25 00:16:30 +0200)
----------------------------------------------------------------
Benjamin Poirier (2):
menuconfig: Fix memory leak introduced by jump keys feature
menuconfig: Add "breadcrumbs" navigation aid
Yann E. MORIN (6):
kconfig/lxdialog: rationalise the include paths where to find {.n}curses{,w}.h
kconfig: fix randconfig tristate detection
kconfig: do not override symbols already set
kconfig: fix randomising choice entries in presence of KCONFIG_ALLCONFIG
kconfig: allow specifying the seed for randconfig
kconfig: implement KCONFIG_PROBABILITY for randconfig
Documentation/kbuild/kconfig.txt | 36 ++++++++++++++ scripts/kconfig/conf.c | 12 ++++- scripts/kconfig/confdata.c | 66 ++++++++++++++++++++++--- scripts/kconfig/list.h | 40 +++++++++++++++ scripts/kconfig/lxdialog/check-lxdialog.sh | 4 +- scripts/kconfig/lxdialog/dialog.h | 7 +++ scripts/kconfig/lxdialog/util.c | 45 ++++++++++++++++- scripts/kconfig/mconf.c | 74 +++++++++++++++++++++++++++- 8 files changed, 271 insertions(+), 13 deletions(-)
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'
PATCH 2/8 menuconfig: Add "breadcrumbs" navigation aid
From: Benjamin Poirier <[email protected]>
Displays a trail of the menu entries used to get to the current menu.
--- scripts/kconfig/list.h | 27 ++++++++++++++ scripts/kconfig/lxdialog/dialog.h | 7 ++++ scripts/kconfig/lxdialog/util.c | 45 +++++++++++++++++++++-- scripts/kconfig/mconf.c | 71 ++++++++++++++++++++++++++++++++++++- 4 files changed, 147 insertions(+), 3 deletions(-)
scripts/kconfig/list.h +27 -0
@@ -101,4 +101,31 @@ static inline void list_add_tail(struct list_head *_new, struct list_head *head) __list_add(_new, head->prev, head); } +/* +* Delete a list entry by making the prev/next entries +* point to each other. +* +* This is only for internal list manipulation where we know +* the prev/next entries already! +*/ +static inline void __list_del (struct list_head *prev,struct list_head *next) +{ + next->prev = prev; + prev->next = next; +} + +#define LIST_POISON1 ((void *) 0x00100100) +#define LIST_POISON2 ((void *) 0x00200200) +/** +* list_del - deletes entry from list. +* @entry: the element to delete from the list. +* Note: list_empty() on entry does not return true after this, the entry is +* in an undefined state. +*/ +static inline void list_del (struct list_head *entry) +{ +__list_del (entry->prev, entry->next); + entry->next =LIST_POISON1 ; + entry->prev =LIST_POISON2 ; +}#endif
scripts/kconfig/lxdialog/dialog.h +7 -0
@@ -106,8 +106,14 @@ struct dialog_color {int hl;/* highlight this item */ }; +struct subtitle_list { +struct subtitle_list *next; +const char *text; +}; +struct dialog_info {const char *backtitle; +struct subtitle_list *subtitles;struct dialog_color screen;struct dialog_color shadow;struct dialog_color dialog;
@@ -196,6 +202,7 @@ int on_key_resize(void);int init_dialog (const char *backtitle);void set_dialog_backtitle (const char *backtitle); +void set_dialog_subtitles (struct subtitle_list *subtitles);void end_dialog (int x,int y);void attr_clear (WINDOW * win,int height,int width,chtype attr);void dialog_clear (void );
scripts/kconfig/lxdialog/util.c +43 -2
61 lines not on this page · raw message
scripts/kconfig/mconf.c +70 -1
141 lines not on this page · raw message
Signature · 1 line
1.7.10.4
PATCH 3/8 kconfig/lxdialog: rationalise the include paths where to find {.n}curses{,w}.h
In reply to Yann E. MORINFrom: "Yann E. MORIN" <[email protected]>
The current code does this:
if [ -f /usr/include/ncursesw/curses.h ]; then
echo '-I/usr/include/ncursesw -DCURSES_LOC="<ncursesw/curses.h>"'
elif [ -f /usr/include/ncurses/ncurses.h ]; then
echo '-I/usr/include/ncurses -DCURSES_LOC="<ncurses.h>"'
elif [ -f /usr/include/ncurses/curses.h ]; then
echo '-I/usr/include/ncurses -DCURSES_LOC="<ncurses/curses.h>"'
[...]
This is merely inconsistent:
- adding the full path to the directory in the -I directive,
- especially since that path is already a sub-path of the system include path,
- and then repeating the sub-path in the #include directive.
Rationalise each include directive:
- only use the filename in the #include directive,
- keep the -I directives: they are always searched for before the system include path; this ensures the correct header is used.
Using the -I directives and the filename-only in #include is more in line with how pkg-config behaves, eg.:
$ pkg-config --cflags ncursesw
-I/usr/include/ncurseswThis paves the way for using pkg-config for CFLAGS, too, now we use it to find the libraries.
--- scripts/kconfig/lxdialog/check-lxdialog.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
scripts/kconfig/lxdialog/check-lxdialog.sh +2 -2
@@ -22,12 +22,12 @@ ldflags() ccflags() { if [ -f /usr/include/ncursesw/curses.h ]; then - echo '-I/usr/include/ncursesw -DCURSES_LOC="<ncursesw/curses.h>"' + echo '-I/usr/include/ncursesw -DCURSES_LOC="<curses.h>"' echo ' -DNCURSES_WIDECHAR=1' elif [ -f /usr/include/ncurses/ncurses.h ]; then echo '-I/usr/include/ncurses -DCURSES_LOC="<ncurses.h>"' elif [ -f /usr/include/ncurses/curses.h ]; then - echo '-I/usr/include/ncurses -DCURSES_LOC="<ncurses/curses.h>"' + echo '-I/usr/include/ncurses -DCURSES_LOC="<curses.h>"' elif [ -f /usr/include/ncurses.h ]; then echo '-DCURSES_LOC="<ncurses.h>"' else
Signature · 1 line
1.7.10.4
PATCH 4/8 kconfig: fix randconfig tristate detection
In reply to Yann E. MORINFrom: "Yann E. MORIN" <[email protected]>
Because the modules' symbole (CONFIG_MODULES) may not yet be set when we check a symbol's tristate capabilty, we'll always find that tristate symbols are booleans, even if we randomly decided that to enable modules:sym_get_type(sym) always return boolean for tristates when modules_sym has not been previously set to 'y' *and* its value calculated *and* its visibility calculated, both of which only occur after we randomly assign values to symbols.
Fix that by looking at the raw type of symbols. Tristate set to 'm' will be promoted to 'y' when their values will be later calculated.
--- scripts/kconfig/confdata.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
scripts/kconfig/confdata.c +1 -1
@@ -1125,7 +1125,7 @@ void conf_set_all_new_symbols(enum conf_def_mode mode) sym->def[S_DEF_USER ].tri = no;break ;case def_random: - cnt =sym_get_type (sym) ==S_TRISTATE ?3 :2 ; + cnt = sym->type ==S_TRISTATE ?3 :2 ; sym->def[S_DEF_USER ].tri = (tristate)(rand () % cnt);break ;default :
Signature · 1 line
1.7.10.4
PATCH 5/8 kconfig: do not override symbols already set
In reply to Yann E. MORINFrom: "Yann E. MORIN" <[email protected]>
For randconfig, if a list of required symbols is specified with KCONFIG_ALLCONFIG, such symbols do not "have a value" as per sym_has_value(), but have the "valid" flag set.
--- scripts/kconfig/confdata.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
scripts/kconfig/confdata.c +1 -1
@@ -1109,7 +1109,7 @@ void conf_set_all_new_symbols(enum conf_def_mode mode)int i, cnt; for_all_symbols(i, sym) { -if (sym_has_value (sym)) +if (sym_has_value (sym) || (sym->flags &SYMBOL_VALID ))continue ;switch (sym_get_type (sym)) {case S_BOOLEAN :
Signature · 1 line
1.7.10.4
PATCH 6/8 kconfig: fix randomising choice entries in presence of KCONFIG_ALLCONFIG
In reply to Yann E. MORINFrom: "Yann E. MORIN" <[email protected]>
Currently, randconfig does randomise choice entries, unless KCONFIG_ALLCONFIG is specified.
For example, given those two files (Thomas' test-case):
---8<--- Config.test.in
config OPTIONA
bool "Option A"
choice
prompt "This is a choice"
config CHOICE_OPTIONA
bool "Choice Option A"
config CHOICE_OPTIONB
bool "Choice Option B"
endchoice
config OPTIONB
bool "Option B"
---8<--- Config.test.in
---8<--- config.defaults
CONFIG_OPTIONA=y
---8<--- config.defaults
And running:
./scripts/kconfig/conf --randconfig Config.test.in
does properly randomise the two choice symbols (and the two booleans).
However, running:
KCONFIG_ALLCONFIG=config.defaults \
./scripts/kconfig/conf --randconfig Config.test.indoes *not* reandomise the two choice entries, and only CHOICE_OPTIONA will ever be selected. (OPTIONA will always be set (expected), and OPTIONB will be be properly randomised (expected).)
This patch defers setting that a choice has a value until a symbol for that choice is indeed set, so that choices are properly randomised when KCONFIG_ALLCONFIG is set, but not if a symbol for that choice is set.
Also, as a side-efect, this patch fixes the following case:
---8<---
choice
config OPTION_A
bool "Option A"
config OPTION_B
bool "Option B"
config OPTION_C
bool "Option C"
endchoice
---8<---
which could previously generate such .config files:
---8<--- ---8<---
CONFIG_OPTION_A=y CONFIG_OPTION_A=y
CONFIG_OPTION_B=y # CONFIG_OPTION_B is not set
# CONFIG_OPTION_C is not set CONFIG_OPTION_C=y
---8<--- ---8<---Ie., the first entry in a choice is always set, plus zero or one of the other options may be set.
This patch ensures that only one option may be set for a choice.
---
Changes v2 -> v3
- ensure only one symbol is set in a choice
Changes v1 -> v2:
- further postpone setting that a choice has a value until one is indeed set
- do not print symbols that are part of an invisible choice
--- scripts/kconfig/confdata.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-)
scripts/kconfig/confdata.c +4 -3
@@ -288,8 +288,6 @@ load: for_all_symbols(i, sym) { sym->flags |=SYMBOL_CHANGED ; sym->flags &= ~(def_flags|SYMBOL_VALID ); -if (sym_is_choice (sym)) - sym->flags |= def_flags;switch (sym->type) {case S_INT :case S_HEX :
@@ -379,13 +377,13 @@ setsym:case mod:if (cs->def[def].tri == yes) {conf_warning ("%s creates inconsistent choice state" , sym->name); - cs->flags &= ~def_flags; }break ;case yes:if (cs->def[def].tri != no)conf_warning ("override: %s changes choice state" , sym->name); cs->def[def].val = sym; + cs->flags |= def_flags;break ; } cs->def[def].tri =EXPR_OR (cs->def[def].tri, sym->def[def].tri);
@@ -791,6 +789,8 @@ int conf_write(const char *name)sym_calc_value (sym);if (!(sym->flags &SYMBOL_WRITE )) goto next; +if (sym_is_choice_value (sym) && !menu_is_visible (menu->parent)) + goto next; sym->flags &= ~SYMBOL_WRITE ;conf_write_symbol (out, sym, &kconfig_printer_cb,NULL );
@@ -1077,6 +1077,7 @@ static void randomize_choice_values(struct symbol *csym)else { sym->def[S_DEF_USER ].tri = no; } + sym->flags &= ~(SYMBOL_VALID ); } csym->flags |=SYMBOL_DEF_USER ;/* clear VALID to get value calculated */
Signature · 1 line
1.7.10.4
PATCH 7/8 kconfig: allow specifying the seed for randconfig
In reply to Yann E. MORINFrom: "Yann E. MORIN" <[email protected]>
For reproducibility, it can be useful to be able to specify the seed to use to seed the RNG.
Add a new KCONFIG_SEED environment variable which can be set to the seed to use:
$ make KCONFIG_SEED=42 randconfig
$ sha1sum .config
70a128c8dcc61303069e1be352cce64114dfcbca .config
$ make KCONFIG_SEED=42 randconfig
$ sha1sum .config
70a128c8dcc61303069e1be352cce64114dfcbca .configIt's very usefull for eg. debugging the kconfig parser.
--- Documentation/kbuild/kconfig.txt | 9 +++++++++ scripts/kconfig/conf.c | 12 +++++++++++- 2 files changed, 20 insertions(+), 1 deletion(-)
Documentation/kbuild/kconfig.txt +9 -0
@@ -90,6 +90,15 @@ disable the options that are explicitly listed in the specified mini-config files. ______________________________________________________________________ +Environment variables for 'randconfig' + +KCONFIG_SEED +-------------------------------------------------- +You can set this to the integer value used to seed the RNG, if you want +to somehow debug the behaviour of the kconfig parser/frontends. +If not set, the current time will be used. + +______________________________________________________________________ Environment variables for 'silentoldconfig' KCONFIG_NOSILENTUPDATE
scripts/kconfig/conf.c +11 -1
@@ -13,6 +13,7 @@#include <getopt.h> #include <sys/stat.h> #include <sys/time.h> +#include <errno.h> #include "lkc.h"
@@ -514,14 +515,23 @@ int main(int ac, char **av) {struct timeval now;unsigned int seed; +char *seed_env;/* * Use microseconds derived seed, * compensate for systems where it may be zero */ gettimeofday (&now,NULL ); - seed = (unsigned int )((now.tv_sec +1 ) * (now.tv_usec +1 )); + + seed_env =getenv ("KCONFIG_SEED" ); +if ( seed_env && *seed_env ) { +char *endp; +int tmp = (int )strtol (seed_env, &endp,10 ); +if (*endp =='\0' ) { + seed = tmp; + } + }srand (seed);break ; }
Signature · 1 line
1.7.10.4
PATCH 8/8 kconfig: implement KCONFIG_PROBABILITY for randconfig
In reply to Yann E. MORINFrom: "Yann E. MORIN" <[email protected]>
Currently the odds to set each symbol is (rounded):
booleans: y: 50% n: 50%
tristates: y: 33% m: 33% n: 33%Introduce a KCONFIG_PROBABILITY environment variable to tweak the probabilities (in percentage), as such:
KCONFIG_PROBABILITY y:n split y:m:n split
-----------------------------------------------------------------
[1] unset or empty 50 : 50 33 : 33 : 34
[2] N N : 100-N N/2 : N/2 : 100-N
N:M N+M : 100-(N+M) N : M : 100-(N+M)
N:M:L N : 100-N M : L : 100-(M+L)[1] The current behaviour is kept as default, for backward compatibility
[2] The solution initially implemented by Peter for Buildroot, see:
http://git.buildroot.org/buildroot/commit/?id=3435c1afb5
--- Documentation/kbuild/kconfig.txt | 27 ++++++++++++++++++ scripts/kconfig/confdata.c | 57 ++++++++++++++++++++++++++++++++++++-- 2 files changed, 81 insertions(+), 3 deletions(-)
Documentation/kbuild/kconfig.txt +27 -0
@@ -98,6 +98,33 @@ You can set this to the integer value used to seed the RNG, if you want to somehow debug the behaviour of the kconfig parser/frontends. If not set, the current time will be used. +KCONFIG_PROBABILITY +-------------------------------------------------- +This variable can be used to skew the probabilities. This variable can +be unset or empty, or set to three different formats: + KCONFIG_PROBABILITY y:n split y:m:n split + ----------------------------------------------------------------- + unset or empty 50 : 50 33 : 33 : 34 + N N : 100-N N/2 : N/2 : 100-N + [1] N:M N+M : 100-(N+M) N : M : 100-(N+M) + [2] N:M:L N : 100-N M : L : 100-(M+L) + +where N, M and L are integers (in base 10) in the range [0,100], and so +that: + [1] N+M is in the range [0,100] + [2] M+L is in the range [0,100] + +Examples: + KCONFIG_PROBABILITY=10 + 10% of booleans will be set to 'y', 90% to 'n' + 5% of tristates will be set to 'y', 5% to 'm', 90% to 'n' + KCONFIG_PROBABILITY=15:25 + 40% of booleans will be set to 'y', 60% to 'n' + 15% of tristates will be set to 'y', 25% to 'm', 60% to 'n' + KCONFIG_PROBABILITY=10:15:15 + 10% of booleans will be set to 'y', 90% to 'n' + 15% of tristates will be set to 'y', 15% to 'm', 70% to 'n' + ______________________________________________________________________ Environment variables for 'silentoldconfig'
scripts/kconfig/confdata.c +54 -3
69 lines not on this page · raw message
Signature · 1 line
1.7.10.4
Re: [PATCH 8/8] kconfig: implement KCONFIG_PROBABILITY for randconfig
Quoted 6 lines · Yann E. MORIN
From: "Yann E. MORIN" <[email protected]>
Currently the odds to set each symbol is (rounded):
booleans: y: 50% n: 50% tristates: y: 33% m: 33% n: 33%
Quoted 8 lines
Introduce a
KCONFIG_PROBABILITYenvironment variable to tweak the probabilities (in percentage), as such:
KCONFIG_PROBABILITYy:n split y:m:n split
-----------------------------------------------------------------[1] unset or empty 50 : 50 33 : 33 : 34 [2] N N : 100-N N/2 : N/2 : 100-N N:M N+M : 100-(N+M) N : M : 100-(N+M) N:M:L N : 100-N M : L : 100-(M+L)
I did a naive test with the current kconfig branch and with yem-kconfig-for-next:
$ git checkout a45c7df $ echo CONFIG_MODULES=y >all.config $ >test-orig; for i in `seq 1000`; do KCONFIG_ALLCONFIG=1 make randconfig || break; grep -c '=m' .config >>test-orig; done ... $ git checkout e43956e $ >test-new; ...
$ awk '{ sum += $1; num++ } END { print sum / num}' test-orig
573.247
$ awk '{ sum += $1; num++ } END { print sum / num}' test-new
565.194I am not a statistician, but this looks OK to me. For reference, the figure was ~340 with the previous patch.
I pulled your changes to kbuild.git#kconfig.
Thanks,
Michal
Re: [PATCH 6/8] kconfig: fix randomising choice entries in presence of KCONFIG_ALLCONFIG
In reply to Yann E. MORINQuoted 6 lines · On Thursday 25 April 2013 00:29:53 Yann E. MORIN wrote:
From: "Yann E. MORIN" <[email protected]>
Currently, randconfig does randomise choice entries, unless
KCONFIG_ALLCONFIGis specified.For example, given those two files (Thomas' test-case):
This patch has made it into linux-next today, and while I agree with the basic idea, it seems to cause regressions for me.
For these ARM defconfigs, 'make' always asks about USB_GADGET now after doing any of these defconfigs:
am200epdkit_defconfigat91_dt_defconfigat91rm9200_defconfigat91sam9260_defconfigat91sam9261_defconfigat91sam9263_defconfigat91sam9g20_defconfigat91sam9g45_defconfigcorgi_defconfigezx_defconfigh5000_defconfigimote2_defconfigkzm9g_defconfiglpc32xx_defconfiglubbock_defconfigmackerel_defconfigmagician_defconfigmini2440_defconfigmsm_defconfigomap1_defconfigprima2_defconfigsama5_defconfigtct_hammer_defconfig
~/arm-soc$ make at91_dt_defconfig
make[1]: Entering directory `/git/arm-soc'
GEN /git/arm-soc/obj-tmp/Makefile HOSTCC scripts/kconfig/zconf.tab.o HOSTLD scripts/kconfig/conf # # configuration written to .config # make[1]: Leaving directory `/git/arm-soc' ~/arm-soc$ make -sj40 make[1]: Entering directory `/git/arm-soc' GEN /git/arm-soc/obj-tmp/Makefile scripts/kconfig/conf --silentoldconfig Kconfig * * Restart config... * * * USB Gadget Support * USB Gadget Support (USB_GADGET) [Y/n/m/?] y Debugging messages (DEVELOPMENT) (USB_GADGET_DEBUG) [N/y/?] n Debugging information files (DEVELOPMENT) (USB_GADGET_DEBUG_FILES) [N/y/?] n Debugging information files in debugfs (DEVELOPMENT) (USB_GADGET_DEBUG_FS) [N/y/?] n Maximum VBUS Power usage (2-500 mA) (USB_GADGET_VBUS_DRAW) [2] 2 Number of storage pipeline buffers (USB_GADGET_STORAGE_NUM_BUFFERS) [2] 2 USB Gadget Drivers [M/y/?] (NEW)
I'm taking Greg on Cc here so he's aware of the problem and knows it's not caused by any of the USB Kconfig changes that I and others submitted recently. It took me a while to confirm that it's just your patch and not mine that caused the problem.
Arnd
Re: [PATCH 6/8] kconfig: fix randomising choice entries in presence of KCONFIG_ALLCONFIG
Arnd, All,
Quoted 10 lines · Arnd Bergmann
Quoted 6 lines · On Thursday 25 April 2013 00:29:53 Yann E. MORIN wrote:
From: "Yann E. MORIN" <[email protected]>
Currently, randconfig does randomise choice entries, unless
KCONFIG_ALLCONFIGis specified.For example, given those two files (Thomas' test-case):
This patch has made it into linux-next today, and while I agree with the basic idea, it seems to cause regressions for me.
Yes, this has already been noticed. Thanks for the report.
So far, we have a plan B (which is to revert that patch). I'll work on plan A when I'm back home after work (GMT+2 here, so in about 5h from now).
Sorry for the annoyance...
Regards,
Yann E. MORIN.
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'
Re: [PATCH 6/8] kconfig: fix randomising choice entries in presence of KCONFIG_ALLCONFIG
In reply to Arnd BergmannQuoted 6 lines · Arnd Bergmann
Quoted 5 lines · On Thursday 25 April 2013 00:29:53 Yann E. MORIN wrote:
From: "Yann E. MORIN" <[email protected]>
Currently, randconfig does randomise choice entries, unless
KCONFIG_ALLCONFIGis specified.
Quoted 6 lines
Quoted 1 line
For example, given those two files (Thomas' test-case):
This patch has made it into linux-next today, and while I agree with the basic idea, it seems to cause regressions for me.
For these ARM defconfigs, 'make' always asks about
USB_GADGETnow
OK, I threw in the towel on that one for tonight.
I'll send a patch to revert this changeset, in the coming minutes.
It will have to be revisited later on, and hopefully we can come to a proper solution during the pre-rc1 window, or at worst, early during the -rc phase (as I'm on holidays the next two weeks, I should find sometime to gather what remains of my courage to look at that again).
Really sorry for the inconvenience... :-(
Regards,
Yann E. MORIN.
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'
Re: [PATCH 6/8] kconfig: fix randomising choice entries in presence of KCONFIG_ALLCONFIG
Quoted 15 lines · Yann E. MORIN
Quoted 6 lines · Arnd Bergmann
Quoted 5 lines · On Thursday 25 April 2013 00:29:53 Yann E. MORIN wrote:
From: "Yann E. MORIN" <[email protected]>
Currently, randconfig does randomise choice entries, unless
KCONFIG_ALLCONFIGis specified.Quoted 6 lines
Quoted 1 line
For example, given those two files (Thomas' test-case):
This patch has made it into linux-next today, and while I agree with the basic idea, it seems to cause regressions for me.
For these ARM defconfigs, 'make' always asks about
USB_GADGETnow
Quoted 7 lines
OK, I threw in the towel on that one for tonight.
I'll send a patch to revert this changeset, in the coming minutes.It will have to be revisited later on, and hopefully we can come to a proper solution during the pre-rc1 window, or at worst, early during the -rc phase (as I'm on holidays the next two weeks, I should find sometime to gather what remains of my courage to look at that again).
Ok, fair enough. For my own testing, I've actually started relying on the behavior that is meant to be changed by the patch, even though I realize that we should really randomize choice statements.
It's easy enough for me to change my script to always select CONFIG_ARCH_MUTLIPLATFORM for ARM testing in the future.
Arnd
Re: [PATCH 6/8] kconfig: fix randomising choice entries in presence of KCONFIG_ALLCONFIG
Arnd, All,
Quoted 24 lines · Arnd Bergmann
Quoted 15 lines · Yann E. MORIN
Quoted 6 lines · Arnd Bergmann
Quoted 5 lines · On Thursday 25 April 2013 00:29:53 Yann E. MORIN wrote:
From: "Yann E. MORIN" <[email protected]>
Currently, randconfig does randomise choice entries, unless
KCONFIG_ALLCONFIGis specified.Quoted 6 lines
Quoted 1 line
For example, given those two files (Thomas' test-case):
This patch has made it into linux-next today, and while I agree with the basic idea, it seems to cause regressions for me.
For these ARM defconfigs, 'make' always asks about
USB_GADGETnowQuoted 7 lines
OK, I threw in the towel on that one for tonight.
I'll send a patch to revert this changeset, in the coming minutes.It will have to be revisited later on, and hopefully we can come to a proper solution during the pre-rc1 window, or at worst, early during the -rc phase (as I'm on holidays the next two weeks, I should find sometime to gather what remains of my courage to look at that again).
Quoted 6 lines
Ok, fair enough. For my own testing, I've actually started relying on the behavior that is meant to be changed by the patch, even though I realize that we should really randomize choice statements.
It's easy enough for me to change my script to always select
CONFIG_ARCH_MUTLIPLATFORMfor ARM testing in the future.
Fact is, choices are properly randomised, unless KCONFIG_ALLCONFIG is passed.
So, if you currently rely on choices not being randomised, it means you're using KCONFIG_ALLCONFIG [*] so you can set CONFIG_ARCH_MULTIPLATFORM in the defconfig you use.
Which should not change your workflow by much, I believe.
[*] If not, then we have another issue. Can you confirm you're already using KCONFIG_ALLCONFIG? If not, can you explain how you handle CONFIG_ARCH_MULTIPLATFORM always being set?
Regards,
Yann E. MORIN.
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'
Re: [PATCH 6/8] kconfig: fix randomising choice entries in presence of KCONFIG_ALLCONFIG
Quoted 6 lines · Yann E. MORIN
Fact is, choices are properly randomised, unless
KCONFIG_ALLCONFIGis passed.So, if you currently rely on choices not being randomised, it means you're using
KCONFIG_ALLCONFIG[*] so you can setCONFIG_ARCH_MULTIPLATFORMin the defconfig you use.
Yes, you are right, I can easily do this.
Arnd