kconfig: obey KCONFIG_ALLCONFIG choices with randconfig.
[firefly-linux-kernel-4.4.55.git] / scripts / kconfig / conf.c
index a38787a881ea29bd876efdcbc483867827189b9d..8d6f17490c5efe753e34b28e38158997f6226567 100644 (file)
@@ -374,7 +374,8 @@ static int conf_choice(struct menu *menu)
                                continue;
                        break;
                case set_random:
-                       def = (random() % cnt) + 1;
+                       if (is_new)
+                               def = (random() % cnt) + 1;
                case set_default:
                case set_yes:
                case set_mod: