OpenSDE Packages Database (without history before r20070)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

133 lines
4.4 KiB

  1. # --- SDE-COPYRIGHT-NOTE-BEGIN ---
  2. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  3. #
  4. # Filename: package/.../linux26-rt/12-conf-hacks.patch
  5. # Copyright (C) 2008 - 2010 The OpenSDE Project
  6. # Copyright (C) 2004 - 2008 The T2 SDE Project
  7. # Copyright (C) 1998 - 2003 ROCK Linux Project
  8. #
  9. # More information can be found in the files COPYING and README.
  10. #
  11. # This patch file is dual-licensed. It is available under the license the
  12. # patched project is licensed under, as long as it is an OpenSource license
  13. # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
  14. # of the GNU General Public License as published by the Free Software
  15. # Foundation; either version 2 of the License, or (at your option) any later
  16. # version.
  17. # --- SDE-COPYRIGHT-NOTE-END ---
  18. Set all unset options to module. Needed by the OpenSDE Linux kernel
  19. auto configuration.
  20. diff -ruN linux-2.6.32.10-orig/scripts/kconfig/Makefile linux-2.6.32.10/scripts/kconfig/Makefile
  21. --- linux-2.6.32.10-orig/scripts/kconfig/Makefile 2009-12-03 04:51:21.000000000 +0100
  22. +++ linux-2.6.32.10/scripts/kconfig/Makefile 2010-03-25 10:15:26.297247478 +0100
  23. @@ -81,7 +81,7 @@
  24. $(Q)rm -f arch/um/Kconfig.arch
  25. $(Q)rm -f $(obj)/config.pot
  26. -PHONY += randconfig allyesconfig allnoconfig allmodconfig defconfig
  27. +PHONY += randconfig allyesconfig allnoconfig allmodconfig no2modconfig defconfig
  28. randconfig: $(obj)/conf
  29. $< -r $(Kconfig)
  30. @@ -95,6 +95,9 @@
  31. allmodconfig: $(obj)/conf
  32. $< -m $(Kconfig)
  33. +no2modconfig: $(obj)/conf
  34. + $< -M $(Kconfig)
  35. +
  36. defconfig: $(obj)/conf
  37. ifeq ($(KBUILD_DEFCONFIG),)
  38. $< -d $(Kconfig)
  39. @@ -119,6 +122,7 @@
  40. @echo ' randconfig - New config with random answer to all options'
  41. @echo ' defconfig - New config with default answer to all options'
  42. @echo ' allmodconfig - New config selecting modules when possible'
  43. + @echo ' no2modconfig - New config selecting modules for disabled options'
  44. @echo ' allyesconfig - New config where all options are accepted with yes'
  45. @echo ' allnoconfig - New config where all options are answered with no'
  46. diff -ruN linux-2.6.32.10-orig/scripts/kconfig/conf.c linux-2.6.32.10/scripts/kconfig/conf.c
  47. --- linux-2.6.32.10-orig/scripts/kconfig/conf.c 2009-12-03 04:51:21.000000000 +0100
  48. +++ linux-2.6.32.10/scripts/kconfig/conf.c 2010-03-25 10:04:47.777577480 +0100
  49. @@ -23,6 +23,7 @@
  50. ask_all,
  51. ask_new,
  52. ask_silent,
  53. + set_no2mod,
  54. set_default,
  55. set_yes,
  56. set_mod,
  57. @@ -439,7 +440,7 @@
  58. bindtextdomain(PACKAGE, LOCALEDIR);
  59. textdomain(PACKAGE);
  60. - while ((opt = getopt(ac, av, "osdD:nmyrh")) != -1) {
  61. + while ((opt = getopt(ac, av, "osdD:nmMyrh")) != -1) {
  62. switch (opt) {
  63. case 'o':
  64. input_mode = ask_silent;
  65. @@ -461,6 +462,9 @@
  66. case 'm':
  67. input_mode = set_mod;
  68. break;
  69. + case 'M':
  70. + input_mode = set_no2mod;
  71. + break;
  72. case 'y':
  73. input_mode = set_yes;
  74. break;
  75. @@ -548,6 +552,9 @@
  76. else if (!stat("all.config", &tmpstat))
  77. conf_read_simple("all.config", S_DEF_USER);
  78. break;
  79. + case set_no2mod:
  80. + conf_read_simple(".config", S_DEF_USER);
  81. + break;
  82. default:
  83. break;
  84. }
  85. @@ -574,6 +581,9 @@
  86. case set_mod:
  87. conf_set_all_new_symbols(def_mod);
  88. break;
  89. + case set_no2mod:
  90. + conf_set_all_new_symbols(def_no2mod);
  91. + break;
  92. case set_random:
  93. conf_set_all_new_symbols(def_random);
  94. break;
  95. diff -ruN linux-2.6.32.10-orig/scripts/kconfig/confdata.c linux-2.6.32.10/scripts/kconfig/confdata.c
  96. --- linux-2.6.32.10-orig/scripts/kconfig/confdata.c 2009-12-03 04:51:21.000000000 +0100
  97. +++ linux-2.6.32.10/scripts/kconfig/confdata.c 2010-03-25 10:04:47.781566395 +0100
  98. @@ -828,6 +828,17 @@
  99. for_all_symbols(i, sym) {
  100. if (sym_has_value(sym))
  101. continue;
  102. + if ((mode == def_no2mod) && (sym_get_type(sym) == S_TRISTATE)) {
  103. + if (sym_get_tristate_value(sym) == no)
  104. + fprintf(stderr, "Setting %s to 'm'.\n", sym->name);
  105. + if (sym_get_tristate_value(sym) == mod)
  106. + fprintf(stderr, "Keep %s as 'm'.\n", sym->name);
  107. + if (sym_get_tristate_value(sym) != yes)
  108. + sym->def[S_DEF_USER].tri = mod;
  109. + if (!sym_is_choice(sym))
  110. + sym->flags |= SYMBOL_DEF_USER;
  111. + continue;
  112. + }
  113. switch (sym_get_type(sym)) {
  114. case S_BOOLEAN:
  115. case S_TRISTATE:
  116. diff -ruN linux-2.6.32.10-orig/scripts/kconfig/lkc.h linux-2.6.32.10/scripts/kconfig/lkc.h
  117. --- linux-2.6.32.10-orig/scripts/kconfig/lkc.h 2009-12-03 04:51:21.000000000 +0100
  118. +++ linux-2.6.32.10/scripts/kconfig/lkc.h 2010-03-25 10:04:47.777577480 +0100
  119. @@ -46,6 +46,7 @@
  120. def_default,
  121. def_yes,
  122. def_mod,
  123. + def_no2mod,
  124. def_no,
  125. def_random
  126. };