projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0a28c47
)
kconfig: make randconfig fair for booleans
author
Peter Korsgaard
<jacmet@sunsite.dk>
Thu, 22 Jul 2010 12:24:57 +0000
(14:24 +0200)
committer
Michal Marek
<mmarek@suse.cz>
Mon, 26 Jul 2010 13:40:52 +0000
(15:40 +0200)
Give boolean symbols a 50% chance of getting enabled, rather than 67%.
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Acked-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Michal Marek <mmarek@suse.cz>
scripts/kconfig/confdata.c
patch
|
blob
|
blame
|
history
diff --git
a/scripts/kconfig/confdata.c
b/scripts/kconfig/confdata.c
index c4dec80cfd8e14a94792af807da0e9705256257d..210a49e27d4702869f1d98316051db758627ab99 100644
(file)
--- a/
scripts/kconfig/confdata.c
+++ b/
scripts/kconfig/confdata.c
@@
-862,7
+862,8
@@
void conf_set_all_new_symbols(enum conf_def_mode mode)
sym->def[S_DEF_USER].tri = no;
break;
case def_random:
- sym->def[S_DEF_USER].tri = (tristate)(rand() % 3);
+ cnt = sym_get_type(sym) == S_TRISTATE ? 3 : 2;
+ sym->def[S_DEF_USER].tri = (tristate)(rand() % cnt);
break;
default:
continue;