diff options
Diffstat (limited to 'scripts/kconfig/conf.c')
-rw-r--r-- | scripts/kconfig/conf.c | 25 |
1 files changed, 16 insertions, 9 deletions
diff --git a/scripts/kconfig/conf.c b/scripts/kconfig/conf.c index 0dc4a2c779b1..4da3b4adfad2 100644 --- a/scripts/kconfig/conf.c +++ b/scripts/kconfig/conf.c | |||
@@ -32,7 +32,7 @@ enum input_mode { | |||
32 | defconfig, | 32 | defconfig, |
33 | savedefconfig, | 33 | savedefconfig, |
34 | listnewconfig, | 34 | listnewconfig, |
35 | oldnoconfig, | 35 | olddefconfig, |
36 | } input_mode = oldaskconfig; | 36 | } input_mode = oldaskconfig; |
37 | 37 | ||
38 | static int indent = 1; | 38 | static int indent = 1; |
@@ -365,7 +365,7 @@ static void conf(struct menu *menu) | |||
365 | case P_MENU: | 365 | case P_MENU: |
366 | if ((input_mode == silentoldconfig || | 366 | if ((input_mode == silentoldconfig || |
367 | input_mode == listnewconfig || | 367 | input_mode == listnewconfig || |
368 | input_mode == oldnoconfig) && | 368 | input_mode == olddefconfig) && |
369 | rootEntry != menu) { | 369 | rootEntry != menu) { |
370 | check_conf(menu); | 370 | check_conf(menu); |
371 | return; | 371 | return; |
@@ -429,7 +429,7 @@ static void check_conf(struct menu *menu) | |||
429 | if (sym->name && !sym_is_choice_value(sym)) { | 429 | if (sym->name && !sym_is_choice_value(sym)) { |
430 | printf("%s%s\n", CONFIG_, sym->name); | 430 | printf("%s%s\n", CONFIG_, sym->name); |
431 | } | 431 | } |
432 | } else if (input_mode != oldnoconfig) { | 432 | } else if (input_mode != olddefconfig) { |
433 | if (!conf_cnt++) | 433 | if (!conf_cnt++) |
434 | printf(_("*\n* Restart config...\n*\n")); | 434 | printf(_("*\n* Restart config...\n*\n")); |
435 | rootEntry = menu_get_parent_menu(menu); | 435 | rootEntry = menu_get_parent_menu(menu); |
@@ -454,7 +454,13 @@ static struct option long_opts[] = { | |||
454 | {"alldefconfig", no_argument, NULL, alldefconfig}, | 454 | {"alldefconfig", no_argument, NULL, alldefconfig}, |
455 | {"randconfig", no_argument, NULL, randconfig}, | 455 | {"randconfig", no_argument, NULL, randconfig}, |
456 | {"listnewconfig", no_argument, NULL, listnewconfig}, | 456 | {"listnewconfig", no_argument, NULL, listnewconfig}, |
457 | {"oldnoconfig", no_argument, NULL, oldnoconfig}, | 457 | {"olddefconfig", no_argument, NULL, olddefconfig}, |
458 | /* | ||
459 | * oldnoconfig is an alias of olddefconfig, because people already | ||
460 | * are dependent on its behavior(sets new symbols to their default | ||
461 | * value but not 'n') with the counter-intuitive name. | ||
462 | */ | ||
463 | {"oldnoconfig", no_argument, NULL, olddefconfig}, | ||
458 | {NULL, 0, NULL, 0} | 464 | {NULL, 0, NULL, 0} |
459 | }; | 465 | }; |
460 | 466 | ||
@@ -467,7 +473,8 @@ static void conf_usage(const char *progname) | |||
467 | printf(" --oldaskconfig Start a new configuration using a line-oriented program\n"); | 473 | printf(" --oldaskconfig Start a new configuration using a line-oriented program\n"); |
468 | printf(" --oldconfig Update a configuration using a provided .config as base\n"); | 474 | printf(" --oldconfig Update a configuration using a provided .config as base\n"); |
469 | printf(" --silentoldconfig Same as oldconfig, but quietly, additionally update deps\n"); | 475 | printf(" --silentoldconfig Same as oldconfig, but quietly, additionally update deps\n"); |
470 | printf(" --oldnoconfig Same as silentoldconfig but set new symbols to no\n"); | 476 | printf(" --olddefconfig Same as silentoldconfig but sets new symbols to their default value\n"); |
477 | printf(" --oldnoconfig An alias of olddefconfig\n"); | ||
471 | printf(" --defconfig <file> New config with default defined in <file>\n"); | 478 | printf(" --defconfig <file> New config with default defined in <file>\n"); |
472 | printf(" --savedefconfig <file> Save the minimal current configuration to <file>\n"); | 479 | printf(" --savedefconfig <file> Save the minimal current configuration to <file>\n"); |
473 | printf(" --allnoconfig New config where all options are answered with no\n"); | 480 | printf(" --allnoconfig New config where all options are answered with no\n"); |
@@ -520,7 +527,7 @@ int main(int ac, char **av) | |||
520 | case allmodconfig: | 527 | case allmodconfig: |
521 | case alldefconfig: | 528 | case alldefconfig: |
522 | case listnewconfig: | 529 | case listnewconfig: |
523 | case oldnoconfig: | 530 | case olddefconfig: |
524 | break; | 531 | break; |
525 | case '?': | 532 | case '?': |
526 | conf_usage(progname); | 533 | conf_usage(progname); |
@@ -565,7 +572,7 @@ int main(int ac, char **av) | |||
565 | case oldaskconfig: | 572 | case oldaskconfig: |
566 | case oldconfig: | 573 | case oldconfig: |
567 | case listnewconfig: | 574 | case listnewconfig: |
568 | case oldnoconfig: | 575 | case olddefconfig: |
569 | conf_read(NULL); | 576 | conf_read(NULL); |
570 | break; | 577 | break; |
571 | case allnoconfig: | 578 | case allnoconfig: |
@@ -645,7 +652,7 @@ int main(int ac, char **av) | |||
645 | /* fall through */ | 652 | /* fall through */ |
646 | case oldconfig: | 653 | case oldconfig: |
647 | case listnewconfig: | 654 | case listnewconfig: |
648 | case oldnoconfig: | 655 | case olddefconfig: |
649 | case silentoldconfig: | 656 | case silentoldconfig: |
650 | /* Update until a loop caused no more changes */ | 657 | /* Update until a loop caused no more changes */ |
651 | do { | 658 | do { |
@@ -653,7 +660,7 @@ int main(int ac, char **av) | |||
653 | check_conf(&rootmenu); | 660 | check_conf(&rootmenu); |
654 | } while (conf_cnt && | 661 | } while (conf_cnt && |
655 | (input_mode != listnewconfig && | 662 | (input_mode != listnewconfig && |
656 | input_mode != oldnoconfig)); | 663 | input_mode != olddefconfig)); |
657 | break; | 664 | break; |
658 | } | 665 | } |
659 | 666 | ||