Kconfig.debug 7.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233
  1. config PRINTK_TIME
  2. bool "Show timing information on printks"
  3. help
  4. Selecting this option causes timing information to be
  5. included in printk output. This allows you to measure
  6. the interval between kernel operations, including bootup
  7. operations. This is useful for identifying long delays
  8. in kernel startup.
  9. config MAGIC_SYSRQ
  10. bool "Magic SysRq key"
  11. depends on !UML
  12. help
  13. If you say Y here, you will have some control over the system even
  14. if the system crashes for example during kernel debugging (e.g., you
  15. will be able to flush the buffer cache to disk, reboot the system
  16. immediately or dump some status information). This is accomplished
  17. by pressing various keys while holding SysRq (Alt+PrintScreen). It
  18. also works on a serial console (on PC hardware at least), if you
  19. send a BREAK and then within 5 seconds a command keypress. The
  20. keys are documented in <file:Documentation/sysrq.txt>. Don't say Y
  21. unless you really know what this hack does.
  22. config DEBUG_KERNEL
  23. bool "Kernel debugging"
  24. help
  25. Say Y here if you are developing drivers or trying to debug and
  26. identify kernel problems.
  27. config LOG_BUF_SHIFT
  28. int "Kernel log buffer size (16 => 64KB, 17 => 128KB)" if DEBUG_KERNEL
  29. range 12 21
  30. default 17 if S390
  31. default 16 if X86_NUMAQ || IA64
  32. default 15 if SMP
  33. default 14
  34. help
  35. Select kernel log buffer size as a power of 2.
  36. Defaults and Examples:
  37. 17 => 128 KB for S/390
  38. 16 => 64 KB for x86 NUMAQ or IA-64
  39. 15 => 32 KB for SMP
  40. 14 => 16 KB for uniprocessor
  41. 13 => 8 KB
  42. 12 => 4 KB
  43. config DETECT_SOFTLOCKUP
  44. bool "Detect Soft Lockups"
  45. depends on DEBUG_KERNEL
  46. default y
  47. help
  48. Say Y here to enable the kernel to detect "soft lockups",
  49. which are bugs that cause the kernel to loop in kernel
  50. mode for more than 10 seconds, without giving other tasks a
  51. chance to run.
  52. When a soft-lockup is detected, the kernel will print the
  53. current stack trace (which you should report), but the
  54. system will stay locked up. This feature has negligible
  55. overhead.
  56. (Note that "hard lockups" are separate type of bugs that
  57. can be detected via the NMI-watchdog, on platforms that
  58. support it.)
  59. config SCHEDSTATS
  60. bool "Collect scheduler statistics"
  61. depends on DEBUG_KERNEL && PROC_FS
  62. help
  63. If you say Y here, additional code will be inserted into the
  64. scheduler and related routines to collect statistics about
  65. scheduler behavior and provide them in /proc/schedstat. These
  66. stats may be useful for both tuning and debugging the scheduler
  67. If you aren't debugging the scheduler or trying to tune a specific
  68. application, you can say N to avoid the very slight overhead
  69. this adds.
  70. config DEBUG_SLAB
  71. bool "Debug slab memory allocations"
  72. depends on DEBUG_KERNEL && SLAB
  73. help
  74. Say Y here to have the kernel do limited verification on memory
  75. allocation as well as poisoning memory on free to catch use of freed
  76. memory. This can make kmalloc/kfree-intensive workloads much slower.
  77. config DEBUG_SLAB_LEAK
  78. bool "Memory leak debugging"
  79. depends on DEBUG_SLAB
  80. config DEBUG_PREEMPT
  81. bool "Debug preemptible kernel"
  82. depends on DEBUG_KERNEL && PREEMPT
  83. default y
  84. help
  85. If you say Y here then the kernel will use a debug variant of the
  86. commonly used smp_processor_id() function and will print warnings
  87. if kernel code uses it in a preemption-unsafe way. Also, the kernel
  88. will detect preemption count underflows.
  89. config DEBUG_MUTEXES
  90. bool "Mutex debugging, deadlock detection"
  91. default n
  92. depends on DEBUG_KERNEL
  93. help
  94. This allows mutex semantics violations and mutex related deadlocks
  95. (lockups) to be detected and reported automatically.
  96. config DEBUG_SPINLOCK
  97. bool "Spinlock debugging"
  98. depends on DEBUG_KERNEL
  99. help
  100. Say Y here and build SMP to catch missing spinlock initialization
  101. and certain other kinds of spinlock errors commonly made. This is
  102. best used in conjunction with the NMI watchdog so that spinlock
  103. deadlocks are also debuggable.
  104. config DEBUG_SPINLOCK_SLEEP
  105. bool "Sleep-inside-spinlock checking"
  106. depends on DEBUG_KERNEL
  107. help
  108. If you say Y here, various routines which may sleep will become very
  109. noisy if they are called with a spinlock held.
  110. config DEBUG_KOBJECT
  111. bool "kobject debugging"
  112. depends on DEBUG_KERNEL
  113. help
  114. If you say Y here, some extra kobject debugging messages will be sent
  115. to the syslog.
  116. config DEBUG_HIGHMEM
  117. bool "Highmem debugging"
  118. depends on DEBUG_KERNEL && HIGHMEM
  119. help
  120. This options enables addition error checking for high memory systems.
  121. Disable for production systems.
  122. config DEBUG_BUGVERBOSE
  123. bool "Verbose BUG() reporting (adds 70K)" if DEBUG_KERNEL && EMBEDDED
  124. depends on BUG
  125. depends on ARM || ARM26 || M32R || M68K || SPARC32 || SPARC64 || X86_32 || FRV
  126. default !EMBEDDED
  127. help
  128. Say Y here to make BUG() panics output the file name and line number
  129. of the BUG call as well as the EIP and oops trace. This aids
  130. debugging but costs about 70-100K of memory.
  131. config DEBUG_INFO
  132. bool "Compile the kernel with debug info"
  133. depends on DEBUG_KERNEL
  134. help
  135. If you say Y here the resulting kernel image will include
  136. debugging info resulting in a larger kernel image.
  137. Say Y here only if you plan to debug the kernel.
  138. If unsure, say N.
  139. config DEBUG_FS
  140. bool "Debug Filesystem"
  141. depends on SYSFS
  142. help
  143. debugfs is a virtual file system that kernel developers use to put
  144. debugging files into. Enable this option to be able to read and
  145. write to these files.
  146. If unsure, say N.
  147. config DEBUG_VM
  148. bool "Debug VM"
  149. depends on DEBUG_KERNEL
  150. help
  151. Enable this to turn on extended checks in the virtual-memory system
  152. that may impact performance.
  153. If unsure, say N.
  154. config FRAME_POINTER
  155. bool "Compile the kernel with frame pointers"
  156. depends on DEBUG_KERNEL && (X86 || CRIS || M68K || M68KNOMMU || FRV || UML)
  157. default y if DEBUG_INFO && UML
  158. help
  159. If you say Y here the resulting kernel image will be slightly larger
  160. and slower, but it might give very useful debugging information on
  161. some architectures or if you use external debuggers.
  162. If you don't debug the kernel, you can say N.
  163. config UNWIND_INFO
  164. bool "Compile the kernel with frame unwind information"
  165. depends on !IA64 && !PARISC
  166. depends on !MODULES || !(MIPS || PPC || SUPERH || V850)
  167. help
  168. If you say Y here the resulting kernel image will be slightly larger
  169. but not slower, and it will give very useful debugging information.
  170. If you don't debug the kernel, you can say N, but we may not be able
  171. to solve problems without frame unwind information or frame pointers.
  172. config STACK_UNWIND
  173. bool "Stack unwind support"
  174. depends on UNWIND_INFO
  175. depends on X86
  176. help
  177. This enables more precise stack traces, omitting all unrelated
  178. occurrences of pointers into kernel code from the dump.
  179. config FORCED_INLINING
  180. bool "Force gcc to inline functions marked 'inline'"
  181. depends on DEBUG_KERNEL
  182. default y
  183. help
  184. This option determines if the kernel forces gcc to inline the functions
  185. developers have marked 'inline'. Doing so takes away freedom from gcc to
  186. do what it thinks is best, which is desirable for the gcc 3.x series of
  187. compilers. The gcc 4.x series have a rewritten inlining algorithm and
  188. disabling this option will generate a smaller kernel there. Hopefully
  189. this algorithm is so good that allowing gcc4 to make the decision can
  190. become the default in the future, until then this option is there to
  191. test gcc for this.
  192. config RCU_TORTURE_TEST
  193. tristate "torture tests for RCU"
  194. depends on DEBUG_KERNEL
  195. default n
  196. help
  197. This option provides a kernel module that runs torture tests
  198. on the RCU infrastructure. The kernel module may be built
  199. after the fact on the running kernel to be tested, if desired.
  200. Say Y here if you want RCU torture tests to start automatically
  201. at boot time (you probably don't).
  202. Say M if you want the RCU torture tests to build as a module.
  203. Say N if you are unsure.