Kconfig.debug 49 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424
  1. config PRINTK_TIME
  2. bool "Show timing information on printks"
  3. depends on PRINTK
  4. help
  5. Selecting this option causes time stamps of the printk()
  6. messages to be added to the output of the syslog() system
  7. call and at the console.
  8. The timestamp is always recorded internally, and exported
  9. to /dev/kmsg. This flag just specifies if the timestamp should
  10. be included, not that the timestamp is recorded.
  11. The behavior is also controlled by the kernel command line
  12. parameter printk.time=1. See Documentation/kernel-parameters.txt
  13. config DEFAULT_MESSAGE_LOGLEVEL
  14. int "Default message log level (1-7)"
  15. range 1 7
  16. default "4"
  17. help
  18. Default log level for printk statements with no specified priority.
  19. This was hard-coded to KERN_WARNING since at least 2.6.10 but folks
  20. that are auditing their logs closely may want to set it to a lower
  21. priority.
  22. config ENABLE_WARN_DEPRECATED
  23. bool "Enable __deprecated logic"
  24. default y
  25. help
  26. Enable the __deprecated logic in the kernel build.
  27. Disable this to suppress the "warning: 'foo' is deprecated
  28. (declared at kernel/power/somefile.c:1234)" messages.
  29. config ENABLE_MUST_CHECK
  30. bool "Enable __must_check logic"
  31. default y
  32. help
  33. Enable the __must_check logic in the kernel build. Disable this to
  34. suppress the "warning: ignoring return value of 'foo', declared with
  35. attribute warn_unused_result" messages.
  36. config FRAME_WARN
  37. int "Warn for stack frames larger than (needs gcc 4.4)"
  38. range 0 8192
  39. default 1024 if !64BIT
  40. default 2048 if 64BIT
  41. help
  42. Tell gcc to warn at build time for stack frames larger than this.
  43. Setting this too low will cause a lot of warnings.
  44. Setting it to 0 disables the warning.
  45. Requires gcc 4.4
  46. config MAGIC_SYSRQ
  47. bool "Magic SysRq key"
  48. depends on !UML
  49. help
  50. If you say Y here, you will have some control over the system even
  51. if the system crashes for example during kernel debugging (e.g., you
  52. will be able to flush the buffer cache to disk, reboot the system
  53. immediately or dump some status information). This is accomplished
  54. by pressing various keys while holding SysRq (Alt+PrintScreen). It
  55. also works on a serial console (on PC hardware at least), if you
  56. send a BREAK and then within 5 seconds a command keypress. The
  57. keys are documented in <file:Documentation/sysrq.txt>. Don't say Y
  58. unless you really know what this hack does.
  59. config STRIP_ASM_SYMS
  60. bool "Strip assembler-generated symbols during link"
  61. default n
  62. help
  63. Strip internal assembler-generated symbols during a link (symbols
  64. that look like '.Lxxx') so they don't pollute the output of
  65. get_wchan() and suchlike.
  66. config READABLE_ASM
  67. bool "Generate readable assembler code"
  68. depends on DEBUG_KERNEL
  69. help
  70. Disable some compiler optimizations that tend to generate human unreadable
  71. assembler output. This may make the kernel slightly slower, but it helps
  72. to keep kernel developers who have to stare a lot at assembler listings
  73. sane.
  74. config UNUSED_SYMBOLS
  75. bool "Enable unused/obsolete exported symbols"
  76. default y if X86
  77. help
  78. Unused but exported symbols make the kernel needlessly bigger. For
  79. that reason most of these unused exports will soon be removed. This
  80. option is provided temporarily to provide a transition period in case
  81. some external kernel module needs one of these symbols anyway. If you
  82. encounter such a case in your module, consider if you are actually
  83. using the right API. (rationale: since nobody in the kernel is using
  84. this in a module, there is a pretty good chance it's actually the
  85. wrong interface to use). If you really need the symbol, please send a
  86. mail to the linux kernel mailing list mentioning the symbol and why
  87. you really need it, and what the merge plan to the mainline kernel for
  88. your module is.
  89. config DEBUG_FS
  90. bool "Debug Filesystem"
  91. help
  92. debugfs is a virtual file system that kernel developers use to put
  93. debugging files into. Enable this option to be able to read and
  94. write to these files.
  95. For detailed documentation on the debugfs API, see
  96. Documentation/DocBook/filesystems.
  97. If unsure, say N.
  98. config HEADERS_CHECK
  99. bool "Run 'make headers_check' when building vmlinux"
  100. depends on !UML
  101. help
  102. This option will extract the user-visible kernel headers whenever
  103. building the kernel, and will run basic sanity checks on them to
  104. ensure that exported files do not attempt to include files which
  105. were not exported, etc.
  106. If you're making modifications to header files which are
  107. relevant for userspace, say 'Y', and check the headers
  108. exported to $(INSTALL_HDR_PATH) (usually 'usr/include' in
  109. your build tree), to make sure they're suitable.
  110. config DEBUG_SECTION_MISMATCH
  111. bool "Enable full Section mismatch analysis"
  112. help
  113. The section mismatch analysis checks if there are illegal
  114. references from one section to another section.
  115. During linktime or runtime, some sections are dropped;
  116. any use of code/data previously in these sections would
  117. most likely result in an oops.
  118. In the code, functions and variables are annotated with
  119. __init, __devinit, etc. (see the full list in include/linux/init.h),
  120. which results in the code/data being placed in specific sections.
  121. The section mismatch analysis is always performed after a full
  122. kernel build, and enabling this option causes the following
  123. additional steps to occur:
  124. - Add the option -fno-inline-functions-called-once to gcc commands.
  125. When inlining a function annotated with __init in a non-init
  126. function, we would lose the section information and thus
  127. the analysis would not catch the illegal reference.
  128. This option tells gcc to inline less (but it does result in
  129. a larger kernel).
  130. - Run the section mismatch analysis for each module/built-in.o file.
  131. When we run the section mismatch analysis on vmlinux.o, we
  132. lose valueble information about where the mismatch was
  133. introduced.
  134. Running the analysis for each module/built-in.o file
  135. tells where the mismatch happens much closer to the
  136. source. The drawback is that the same mismatch is
  137. reported at least twice.
  138. - Enable verbose reporting from modpost in order to help resolve
  139. the section mismatches that are reported.
  140. config DEBUG_KERNEL
  141. bool "Kernel debugging"
  142. help
  143. Say Y here if you are developing drivers or trying to debug and
  144. identify kernel problems.
  145. config DEBUG_SHIRQ
  146. bool "Debug shared IRQ handlers"
  147. depends on DEBUG_KERNEL && GENERIC_HARDIRQS
  148. help
  149. Enable this to generate a spurious interrupt as soon as a shared
  150. interrupt handler is registered, and just before one is deregistered.
  151. Drivers ought to be able to handle interrupts coming in at those
  152. points; some don't and need to be caught.
  153. config LOCKUP_DETECTOR
  154. bool "Detect Hard and Soft Lockups"
  155. depends on DEBUG_KERNEL && !S390
  156. help
  157. Say Y here to enable the kernel to act as a watchdog to detect
  158. hard and soft lockups.
  159. Softlockups are bugs that cause the kernel to loop in kernel
  160. mode for more than 20 seconds, without giving other tasks a
  161. chance to run. The current stack trace is displayed upon
  162. detection and the system will stay locked up.
  163. Hardlockups are bugs that cause the CPU to loop in kernel mode
  164. for more than 10 seconds, without letting other interrupts have a
  165. chance to run. The current stack trace is displayed upon detection
  166. and the system will stay locked up.
  167. The overhead should be minimal. A periodic hrtimer runs to
  168. generate interrupts and kick the watchdog task every 4 seconds.
  169. An NMI is generated every 10 seconds or so to check for hardlockups.
  170. The frequency of hrtimer and NMI events and the soft and hard lockup
  171. thresholds can be controlled through the sysctl watchdog_thresh.
  172. config HARDLOCKUP_DETECTOR
  173. def_bool LOCKUP_DETECTOR && PERF_EVENTS && HAVE_PERF_EVENTS_NMI && \
  174. !HAVE_NMI_WATCHDOG
  175. config BOOTPARAM_HARDLOCKUP_PANIC
  176. bool "Panic (Reboot) On Hard Lockups"
  177. depends on LOCKUP_DETECTOR
  178. help
  179. Say Y here to enable the kernel to panic on "hard lockups",
  180. which are bugs that cause the kernel to loop in kernel
  181. mode with interrupts disabled for more than 10 seconds (configurable
  182. using the watchdog_thresh sysctl).
  183. Say N if unsure.
  184. config BOOTPARAM_HARDLOCKUP_PANIC_VALUE
  185. int
  186. depends on LOCKUP_DETECTOR
  187. range 0 1
  188. default 0 if !BOOTPARAM_HARDLOCKUP_PANIC
  189. default 1 if BOOTPARAM_HARDLOCKUP_PANIC
  190. config BOOTPARAM_SOFTLOCKUP_PANIC
  191. bool "Panic (Reboot) On Soft Lockups"
  192. depends on LOCKUP_DETECTOR
  193. help
  194. Say Y here to enable the kernel to panic on "soft lockups",
  195. which are bugs that cause the kernel to loop in kernel
  196. mode for more than 20 seconds (configurable using the watchdog_thresh
  197. sysctl), without giving other tasks a chance to run.
  198. The panic can be used in combination with panic_timeout,
  199. to cause the system to reboot automatically after a
  200. lockup has been detected. This feature is useful for
  201. high-availability systems that have uptime guarantees and
  202. where a lockup must be resolved ASAP.
  203. Say N if unsure.
  204. config BOOTPARAM_SOFTLOCKUP_PANIC_VALUE
  205. int
  206. depends on LOCKUP_DETECTOR
  207. range 0 1
  208. default 0 if !BOOTPARAM_SOFTLOCKUP_PANIC
  209. default 1 if BOOTPARAM_SOFTLOCKUP_PANIC
  210. config PANIC_ON_OOPS
  211. bool "Panic on Oops" if EXPERT
  212. default n
  213. help
  214. Say Y here to enable the kernel to panic when it oopses. This
  215. has the same effect as setting oops=panic on the kernel command
  216. line.
  217. This feature is useful to ensure that the kernel does not do
  218. anything erroneous after an oops which could result in data
  219. corruption or other issues.
  220. Say N if unsure.
  221. config PANIC_ON_OOPS_VALUE
  222. int
  223. range 0 1
  224. default 0 if !PANIC_ON_OOPS
  225. default 1 if PANIC_ON_OOPS
  226. config DETECT_HUNG_TASK
  227. bool "Detect Hung Tasks"
  228. depends on DEBUG_KERNEL
  229. default LOCKUP_DETECTOR
  230. help
  231. Say Y here to enable the kernel to detect "hung tasks",
  232. which are bugs that cause the task to be stuck in
  233. uninterruptible "D" state indefinitiley.
  234. When a hung task is detected, the kernel will print the
  235. current stack trace (which you should report), but the
  236. task will stay in uninterruptible state. If lockdep is
  237. enabled then all held locks will also be reported. This
  238. feature has negligible overhead.
  239. config DEFAULT_HUNG_TASK_TIMEOUT
  240. int "Default timeout for hung task detection (in seconds)"
  241. depends on DETECT_HUNG_TASK
  242. default 120
  243. help
  244. This option controls the default timeout (in seconds) used
  245. to determine when a task has become non-responsive and should
  246. be considered hung.
  247. It can be adjusted at runtime via the kernel.hung_task_timeout_secs
  248. sysctl or by writing a value to
  249. /proc/sys/kernel/hung_task_timeout_secs.
  250. A timeout of 0 disables the check. The default is two minutes.
  251. Keeping the default should be fine in most cases.
  252. config BOOTPARAM_HUNG_TASK_PANIC
  253. bool "Panic (Reboot) On Hung Tasks"
  254. depends on DETECT_HUNG_TASK
  255. help
  256. Say Y here to enable the kernel to panic on "hung tasks",
  257. which are bugs that cause the kernel to leave a task stuck
  258. in uninterruptible "D" state.
  259. The panic can be used in combination with panic_timeout,
  260. to cause the system to reboot automatically after a
  261. hung task has been detected. This feature is useful for
  262. high-availability systems that have uptime guarantees and
  263. where a hung tasks must be resolved ASAP.
  264. Say N if unsure.
  265. config BOOTPARAM_HUNG_TASK_PANIC_VALUE
  266. int
  267. depends on DETECT_HUNG_TASK
  268. range 0 1
  269. default 0 if !BOOTPARAM_HUNG_TASK_PANIC
  270. default 1 if BOOTPARAM_HUNG_TASK_PANIC
  271. config SCHED_DEBUG
  272. bool "Collect scheduler debugging info"
  273. depends on DEBUG_KERNEL && PROC_FS
  274. default y
  275. help
  276. If you say Y here, the /proc/sched_debug file will be provided
  277. that can help debug the scheduler. The runtime overhead of this
  278. option is minimal.
  279. config SCHEDSTATS
  280. bool "Collect scheduler statistics"
  281. depends on DEBUG_KERNEL && PROC_FS
  282. help
  283. If you say Y here, additional code will be inserted into the
  284. scheduler and related routines to collect statistics about
  285. scheduler behavior and provide them in /proc/schedstat. These
  286. stats may be useful for both tuning and debugging the scheduler
  287. If you aren't debugging the scheduler or trying to tune a specific
  288. application, you can say N to avoid the very slight overhead
  289. this adds.
  290. config TIMER_STATS
  291. bool "Collect kernel timers statistics"
  292. depends on DEBUG_KERNEL && PROC_FS
  293. help
  294. If you say Y here, additional code will be inserted into the
  295. timer routines to collect statistics about kernel timers being
  296. reprogrammed. The statistics can be read from /proc/timer_stats.
  297. The statistics collection is started by writing 1 to /proc/timer_stats,
  298. writing 0 stops it. This feature is useful to collect information
  299. about timer usage patterns in kernel and userspace. This feature
  300. is lightweight if enabled in the kernel config but not activated
  301. (it defaults to deactivated on bootup and will only be activated
  302. if some application like powertop activates it explicitly).
  303. config DEBUG_OBJECTS
  304. bool "Debug object operations"
  305. depends on DEBUG_KERNEL
  306. help
  307. If you say Y here, additional code will be inserted into the
  308. kernel to track the life time of various objects and validate
  309. the operations on those objects.
  310. config DEBUG_OBJECTS_SELFTEST
  311. bool "Debug objects selftest"
  312. depends on DEBUG_OBJECTS
  313. help
  314. This enables the selftest of the object debug code.
  315. config DEBUG_OBJECTS_FREE
  316. bool "Debug objects in freed memory"
  317. depends on DEBUG_OBJECTS
  318. help
  319. This enables checks whether a k/v free operation frees an area
  320. which contains an object which has not been deactivated
  321. properly. This can make kmalloc/kfree-intensive workloads
  322. much slower.
  323. config DEBUG_OBJECTS_TIMERS
  324. bool "Debug timer objects"
  325. depends on DEBUG_OBJECTS
  326. help
  327. If you say Y here, additional code will be inserted into the
  328. timer routines to track the life time of timer objects and
  329. validate the timer operations.
  330. config DEBUG_OBJECTS_WORK
  331. bool "Debug work objects"
  332. depends on DEBUG_OBJECTS
  333. help
  334. If you say Y here, additional code will be inserted into the
  335. work queue routines to track the life time of work objects and
  336. validate the work operations.
  337. config DEBUG_OBJECTS_RCU_HEAD
  338. bool "Debug RCU callbacks objects"
  339. depends on DEBUG_OBJECTS
  340. help
  341. Enable this to turn on debugging of RCU list heads (call_rcu() usage).
  342. config DEBUG_OBJECTS_PERCPU_COUNTER
  343. bool "Debug percpu counter objects"
  344. depends on DEBUG_OBJECTS
  345. help
  346. If you say Y here, additional code will be inserted into the
  347. percpu counter routines to track the life time of percpu counter
  348. objects and validate the percpu counter operations.
  349. config DEBUG_OBJECTS_ENABLE_DEFAULT
  350. int "debug_objects bootup default value (0-1)"
  351. range 0 1
  352. default "1"
  353. depends on DEBUG_OBJECTS
  354. help
  355. Debug objects boot parameter default value
  356. config DEBUG_SLAB
  357. bool "Debug slab memory allocations"
  358. depends on DEBUG_KERNEL && SLAB && !KMEMCHECK
  359. help
  360. Say Y here to have the kernel do limited verification on memory
  361. allocation as well as poisoning memory on free to catch use of freed
  362. memory. This can make kmalloc/kfree-intensive workloads much slower.
  363. config DEBUG_SLAB_LEAK
  364. bool "Memory leak debugging"
  365. depends on DEBUG_SLAB
  366. config SLUB_DEBUG_ON
  367. bool "SLUB debugging on by default"
  368. depends on SLUB && SLUB_DEBUG && !KMEMCHECK
  369. default n
  370. help
  371. Boot with debugging on by default. SLUB boots by default with
  372. the runtime debug capabilities switched off. Enabling this is
  373. equivalent to specifying the "slub_debug" parameter on boot.
  374. There is no support for more fine grained debug control like
  375. possible with slub_debug=xxx. SLUB debugging may be switched
  376. off in a kernel built with CONFIG_SLUB_DEBUG_ON by specifying
  377. "slub_debug=-".
  378. config SLUB_STATS
  379. default n
  380. bool "Enable SLUB performance statistics"
  381. depends on SLUB && SYSFS
  382. help
  383. SLUB statistics are useful to debug SLUBs allocation behavior in
  384. order find ways to optimize the allocator. This should never be
  385. enabled for production use since keeping statistics slows down
  386. the allocator by a few percentage points. The slabinfo command
  387. supports the determination of the most active slabs to figure
  388. out which slabs are relevant to a particular load.
  389. Try running: slabinfo -DA
  390. config DEBUG_KMEMLEAK
  391. bool "Kernel memory leak detector"
  392. depends on DEBUG_KERNEL && EXPERIMENTAL && \
  393. (X86 || ARM || PPC || MIPS || S390 || SPARC64 || SUPERH || MICROBLAZE || TILE)
  394. select DEBUG_FS
  395. select STACKTRACE if STACKTRACE_SUPPORT
  396. select KALLSYMS
  397. select CRC32
  398. help
  399. Say Y here if you want to enable the memory leak
  400. detector. The memory allocation/freeing is traced in a way
  401. similar to the Boehm's conservative garbage collector, the
  402. difference being that the orphan objects are not freed but
  403. only shown in /sys/kernel/debug/kmemleak. Enabling this
  404. feature will introduce an overhead to memory
  405. allocations. See Documentation/kmemleak.txt for more
  406. details.
  407. Enabling DEBUG_SLAB or SLUB_DEBUG may increase the chances
  408. of finding leaks due to the slab objects poisoning.
  409. In order to access the kmemleak file, debugfs needs to be
  410. mounted (usually at /sys/kernel/debug).
  411. config DEBUG_KMEMLEAK_EARLY_LOG_SIZE
  412. int "Maximum kmemleak early log entries"
  413. depends on DEBUG_KMEMLEAK
  414. range 200 40000
  415. default 400
  416. help
  417. Kmemleak must track all the memory allocations to avoid
  418. reporting false positives. Since memory may be allocated or
  419. freed before kmemleak is initialised, an early log buffer is
  420. used to store these actions. If kmemleak reports "early log
  421. buffer exceeded", please increase this value.
  422. config DEBUG_KMEMLEAK_TEST
  423. tristate "Simple test for the kernel memory leak detector"
  424. depends on DEBUG_KMEMLEAK && m
  425. help
  426. This option enables a module that explicitly leaks memory.
  427. If unsure, say N.
  428. config DEBUG_KMEMLEAK_DEFAULT_OFF
  429. bool "Default kmemleak to off"
  430. depends on DEBUG_KMEMLEAK
  431. help
  432. Say Y here to disable kmemleak by default. It can then be enabled
  433. on the command line via kmemleak=on.
  434. config DEBUG_PREEMPT
  435. bool "Debug preemptible kernel"
  436. depends on DEBUG_KERNEL && PREEMPT && TRACE_IRQFLAGS_SUPPORT
  437. default y
  438. help
  439. If you say Y here then the kernel will use a debug variant of the
  440. commonly used smp_processor_id() function and will print warnings
  441. if kernel code uses it in a preemption-unsafe way. Also, the kernel
  442. will detect preemption count underflows.
  443. config DEBUG_RT_MUTEXES
  444. bool "RT Mutex debugging, deadlock detection"
  445. depends on DEBUG_KERNEL && RT_MUTEXES
  446. help
  447. This allows rt mutex semantics violations and rt mutex related
  448. deadlocks (lockups) to be detected and reported automatically.
  449. config DEBUG_PI_LIST
  450. bool
  451. default y
  452. depends on DEBUG_RT_MUTEXES
  453. config RT_MUTEX_TESTER
  454. bool "Built-in scriptable tester for rt-mutexes"
  455. depends on DEBUG_KERNEL && RT_MUTEXES
  456. help
  457. This option enables a rt-mutex tester.
  458. config DEBUG_SPINLOCK
  459. bool "Spinlock and rw-lock debugging: basic checks"
  460. depends on DEBUG_KERNEL
  461. select UNINLINE_SPIN_UNLOCK
  462. help
  463. Say Y here and build SMP to catch missing spinlock initialization
  464. and certain other kinds of spinlock errors commonly made. This is
  465. best used in conjunction with the NMI watchdog so that spinlock
  466. deadlocks are also debuggable.
  467. config DEBUG_MUTEXES
  468. bool "Mutex debugging: basic checks"
  469. depends on DEBUG_KERNEL
  470. help
  471. This feature allows mutex semantics violations to be detected and
  472. reported.
  473. config DEBUG_LOCK_ALLOC
  474. bool "Lock debugging: detect incorrect freeing of live locks"
  475. depends on DEBUG_KERNEL && TRACE_IRQFLAGS_SUPPORT && STACKTRACE_SUPPORT && LOCKDEP_SUPPORT
  476. select DEBUG_SPINLOCK
  477. select DEBUG_MUTEXES
  478. select LOCKDEP
  479. help
  480. This feature will check whether any held lock (spinlock, rwlock,
  481. mutex or rwsem) is incorrectly freed by the kernel, via any of the
  482. memory-freeing routines (kfree(), kmem_cache_free(), free_pages(),
  483. vfree(), etc.), whether a live lock is incorrectly reinitialized via
  484. spin_lock_init()/mutex_init()/etc., or whether there is any lock
  485. held during task exit.
  486. config PROVE_LOCKING
  487. bool "Lock debugging: prove locking correctness"
  488. depends on DEBUG_KERNEL && TRACE_IRQFLAGS_SUPPORT && STACKTRACE_SUPPORT && LOCKDEP_SUPPORT
  489. select LOCKDEP
  490. select DEBUG_SPINLOCK
  491. select DEBUG_MUTEXES
  492. select DEBUG_LOCK_ALLOC
  493. select TRACE_IRQFLAGS
  494. default n
  495. help
  496. This feature enables the kernel to prove that all locking
  497. that occurs in the kernel runtime is mathematically
  498. correct: that under no circumstance could an arbitrary (and
  499. not yet triggered) combination of observed locking
  500. sequences (on an arbitrary number of CPUs, running an
  501. arbitrary number of tasks and interrupt contexts) cause a
  502. deadlock.
  503. In short, this feature enables the kernel to report locking
  504. related deadlocks before they actually occur.
  505. The proof does not depend on how hard and complex a
  506. deadlock scenario would be to trigger: how many
  507. participant CPUs, tasks and irq-contexts would be needed
  508. for it to trigger. The proof also does not depend on
  509. timing: if a race and a resulting deadlock is possible
  510. theoretically (no matter how unlikely the race scenario
  511. is), it will be proven so and will immediately be
  512. reported by the kernel (once the event is observed that
  513. makes the deadlock theoretically possible).
  514. If a deadlock is impossible (i.e. the locking rules, as
  515. observed by the kernel, are mathematically correct), the
  516. kernel reports nothing.
  517. NOTE: this feature can also be enabled for rwlocks, mutexes
  518. and rwsems - in which case all dependencies between these
  519. different locking variants are observed and mapped too, and
  520. the proof of observed correctness is also maintained for an
  521. arbitrary combination of these separate locking variants.
  522. For more details, see Documentation/lockdep-design.txt.
  523. config PROVE_RCU
  524. bool "RCU debugging: prove RCU correctness"
  525. depends on PROVE_LOCKING
  526. default n
  527. help
  528. This feature enables lockdep extensions that check for correct
  529. use of RCU APIs. This is currently under development. Say Y
  530. if you want to debug RCU usage or help work on the PROVE_RCU
  531. feature.
  532. Say N if you are unsure.
  533. config PROVE_RCU_REPEATEDLY
  534. bool "RCU debugging: don't disable PROVE_RCU on first splat"
  535. depends on PROVE_RCU
  536. default n
  537. help
  538. By itself, PROVE_RCU will disable checking upon issuing the
  539. first warning (or "splat"). This feature prevents such
  540. disabling, allowing multiple RCU-lockdep warnings to be printed
  541. on a single reboot.
  542. Say Y to allow multiple RCU-lockdep warnings per boot.
  543. Say N if you are unsure.
  544. config SPARSE_RCU_POINTER
  545. bool "RCU debugging: sparse-based checks for pointer usage"
  546. default n
  547. help
  548. This feature enables the __rcu sparse annotation for
  549. RCU-protected pointers. This annotation will cause sparse
  550. to flag any non-RCU used of annotated pointers. This can be
  551. helpful when debugging RCU usage. Please note that this feature
  552. is not intended to enforce code cleanliness; it is instead merely
  553. a debugging aid.
  554. Say Y to make sparse flag questionable use of RCU-protected pointers
  555. Say N if you are unsure.
  556. config LOCKDEP
  557. bool
  558. depends on DEBUG_KERNEL && TRACE_IRQFLAGS_SUPPORT && STACKTRACE_SUPPORT && LOCKDEP_SUPPORT
  559. select STACKTRACE
  560. select FRAME_POINTER if !MIPS && !PPC && !ARM_UNWIND && !S390 && !MICROBLAZE
  561. select KALLSYMS
  562. select KALLSYMS_ALL
  563. config LOCK_STAT
  564. bool "Lock usage statistics"
  565. depends on DEBUG_KERNEL && TRACE_IRQFLAGS_SUPPORT && STACKTRACE_SUPPORT && LOCKDEP_SUPPORT
  566. select LOCKDEP
  567. select DEBUG_SPINLOCK
  568. select DEBUG_MUTEXES
  569. select DEBUG_LOCK_ALLOC
  570. default n
  571. help
  572. This feature enables tracking lock contention points
  573. For more details, see Documentation/lockstat.txt
  574. This also enables lock events required by "perf lock",
  575. subcommand of perf.
  576. If you want to use "perf lock", you also need to turn on
  577. CONFIG_EVENT_TRACING.
  578. CONFIG_LOCK_STAT defines "contended" and "acquired" lock events.
  579. (CONFIG_LOCKDEP defines "acquire" and "release" events.)
  580. config DEBUG_LOCKDEP
  581. bool "Lock dependency engine debugging"
  582. depends on DEBUG_KERNEL && LOCKDEP
  583. help
  584. If you say Y here, the lock dependency engine will do
  585. additional runtime checks to debug itself, at the price
  586. of more runtime overhead.
  587. config TRACE_IRQFLAGS
  588. bool
  589. help
  590. Enables hooks to interrupt enabling and disabling for
  591. either tracing or lock debugging.
  592. config DEBUG_ATOMIC_SLEEP
  593. bool "Sleep inside atomic section checking"
  594. select PREEMPT_COUNT
  595. depends on DEBUG_KERNEL
  596. help
  597. If you say Y here, various routines which may sleep will become very
  598. noisy if they are called inside atomic sections: when a spinlock is
  599. held, inside an rcu read side critical section, inside preempt disabled
  600. sections, inside an interrupt, etc...
  601. config DEBUG_LOCKING_API_SELFTESTS
  602. bool "Locking API boot-time self-tests"
  603. depends on DEBUG_KERNEL
  604. help
  605. Say Y here if you want the kernel to run a short self-test during
  606. bootup. The self-test checks whether common types of locking bugs
  607. are detected by debugging mechanisms or not. (if you disable
  608. lock debugging then those bugs wont be detected of course.)
  609. The following locking APIs are covered: spinlocks, rwlocks,
  610. mutexes and rwsems.
  611. config STACKTRACE
  612. bool
  613. depends on STACKTRACE_SUPPORT
  614. config DEBUG_STACK_USAGE
  615. bool "Stack utilization instrumentation"
  616. depends on DEBUG_KERNEL && !IA64 && !PARISC
  617. help
  618. Enables the display of the minimum amount of free stack which each
  619. task has ever had available in the sysrq-T and sysrq-P debug output.
  620. This option will slow down process creation somewhat.
  621. config DEBUG_KOBJECT
  622. bool "kobject debugging"
  623. depends on DEBUG_KERNEL
  624. help
  625. If you say Y here, some extra kobject debugging messages will be sent
  626. to the syslog.
  627. config DEBUG_HIGHMEM
  628. bool "Highmem debugging"
  629. depends on DEBUG_KERNEL && HIGHMEM
  630. help
  631. This options enables addition error checking for high memory systems.
  632. Disable for production systems.
  633. config DEBUG_BUGVERBOSE
  634. bool "Verbose BUG() reporting (adds 70K)" if DEBUG_KERNEL && EXPERT
  635. depends on BUG
  636. depends on ARM || AVR32 || M32R || M68K || SPARC32 || SPARC64 || \
  637. FRV || SUPERH || GENERIC_BUG || BLACKFIN || MN10300 || TILE
  638. default y
  639. help
  640. Say Y here to make BUG() panics output the file name and line number
  641. of the BUG call as well as the EIP and oops trace. This aids
  642. debugging but costs about 70-100K of memory.
  643. config DEBUG_INFO
  644. bool "Compile the kernel with debug info"
  645. depends on DEBUG_KERNEL
  646. help
  647. If you say Y here the resulting kernel image will include
  648. debugging info resulting in a larger kernel image.
  649. This adds debug symbols to the kernel and modules (gcc -g), and
  650. is needed if you intend to use kernel crashdump or binary object
  651. tools like crash, kgdb, LKCD, gdb, etc on the kernel.
  652. Say Y here only if you plan to debug the kernel.
  653. If unsure, say N.
  654. config DEBUG_INFO_REDUCED
  655. bool "Reduce debugging information"
  656. depends on DEBUG_INFO
  657. help
  658. If you say Y here gcc is instructed to generate less debugging
  659. information for structure types. This means that tools that
  660. need full debugging information (like kgdb or systemtap) won't
  661. be happy. But if you merely need debugging information to
  662. resolve line numbers there is no loss. Advantage is that
  663. build directory object sizes shrink dramatically over a full
  664. DEBUG_INFO build and compile times are reduced too.
  665. Only works with newer gcc versions.
  666. config DEBUG_VM
  667. bool "Debug VM"
  668. depends on DEBUG_KERNEL
  669. help
  670. Enable this to turn on extended checks in the virtual-memory system
  671. that may impact performance.
  672. If unsure, say N.
  673. config DEBUG_VIRTUAL
  674. bool "Debug VM translations"
  675. depends on DEBUG_KERNEL && X86
  676. help
  677. Enable some costly sanity checks in virtual to page code. This can
  678. catch mistakes with virt_to_page() and friends.
  679. If unsure, say N.
  680. config DEBUG_NOMMU_REGIONS
  681. bool "Debug the global anon/private NOMMU mapping region tree"
  682. depends on DEBUG_KERNEL && !MMU
  683. help
  684. This option causes the global tree of anonymous and private mapping
  685. regions to be regularly checked for invalid topology.
  686. config DEBUG_WRITECOUNT
  687. bool "Debug filesystem writers count"
  688. depends on DEBUG_KERNEL
  689. help
  690. Enable this to catch wrong use of the writers count in struct
  691. vfsmount. This will increase the size of each file struct by
  692. 32 bits.
  693. If unsure, say N.
  694. config DEBUG_MEMORY_INIT
  695. bool "Debug memory initialisation" if EXPERT
  696. default !EXPERT
  697. help
  698. Enable this for additional checks during memory initialisation.
  699. The sanity checks verify aspects of the VM such as the memory model
  700. and other information provided by the architecture. Verbose
  701. information will be printed at KERN_DEBUG loglevel depending
  702. on the mminit_loglevel= command-line option.
  703. If unsure, say Y
  704. config DEBUG_LIST
  705. bool "Debug linked list manipulation"
  706. depends on DEBUG_KERNEL
  707. help
  708. Enable this to turn on extended checks in the linked-list
  709. walking routines.
  710. If unsure, say N.
  711. config TEST_LIST_SORT
  712. bool "Linked list sorting test"
  713. depends on DEBUG_KERNEL
  714. help
  715. Enable this to turn on 'list_sort()' function test. This test is
  716. executed only once during system boot, so affects only boot time.
  717. If unsure, say N.
  718. config DEBUG_SG
  719. bool "Debug SG table operations"
  720. depends on DEBUG_KERNEL
  721. help
  722. Enable this to turn on checks on scatter-gather tables. This can
  723. help find problems with drivers that do not properly initialize
  724. their sg tables.
  725. If unsure, say N.
  726. config DEBUG_NOTIFIERS
  727. bool "Debug notifier call chains"
  728. depends on DEBUG_KERNEL
  729. help
  730. Enable this to turn on sanity checking for notifier call chains.
  731. This is most useful for kernel developers to make sure that
  732. modules properly unregister themselves from notifier chains.
  733. This is a relatively cheap check but if you care about maximum
  734. performance, say N.
  735. config DEBUG_CREDENTIALS
  736. bool "Debug credential management"
  737. depends on DEBUG_KERNEL
  738. help
  739. Enable this to turn on some debug checking for credential
  740. management. The additional code keeps track of the number of
  741. pointers from task_structs to any given cred struct, and checks to
  742. see that this number never exceeds the usage count of the cred
  743. struct.
  744. Furthermore, if SELinux is enabled, this also checks that the
  745. security pointer in the cred struct is never seen to be invalid.
  746. If unsure, say N.
  747. #
  748. # Select this config option from the architecture Kconfig, if it
  749. # is preferred to always offer frame pointers as a config
  750. # option on the architecture (regardless of KERNEL_DEBUG):
  751. #
  752. config ARCH_WANT_FRAME_POINTERS
  753. bool
  754. help
  755. config FRAME_POINTER
  756. bool "Compile the kernel with frame pointers"
  757. depends on DEBUG_KERNEL && \
  758. (CRIS || M68K || FRV || UML || \
  759. AVR32 || SUPERH || BLACKFIN || MN10300) || \
  760. ARCH_WANT_FRAME_POINTERS
  761. default y if (DEBUG_INFO && UML) || ARCH_WANT_FRAME_POINTERS
  762. help
  763. If you say Y here the resulting kernel image will be slightly
  764. larger and slower, but it gives very useful debugging information
  765. in case of kernel bugs. (precise oopses/stacktraces/warnings)
  766. config BOOT_PRINTK_DELAY
  767. bool "Delay each boot printk message by N milliseconds"
  768. depends on DEBUG_KERNEL && PRINTK && GENERIC_CALIBRATE_DELAY
  769. help
  770. This build option allows you to read kernel boot messages
  771. by inserting a short delay after each one. The delay is
  772. specified in milliseconds on the kernel command line,
  773. using "boot_delay=N".
  774. It is likely that you would also need to use "lpj=M" to preset
  775. the "loops per jiffie" value.
  776. See a previous boot log for the "lpj" value to use for your
  777. system, and then set "lpj=M" before setting "boot_delay=N".
  778. NOTE: Using this option may adversely affect SMP systems.
  779. I.e., processors other than the first one may not boot up.
  780. BOOT_PRINTK_DELAY also may cause LOCKUP_DETECTOR to detect
  781. what it believes to be lockup conditions.
  782. config RCU_TORTURE_TEST
  783. tristate "torture tests for RCU"
  784. depends on DEBUG_KERNEL
  785. default n
  786. help
  787. This option provides a kernel module that runs torture tests
  788. on the RCU infrastructure. The kernel module may be built
  789. after the fact on the running kernel to be tested, if desired.
  790. Say Y here if you want RCU torture tests to be built into
  791. the kernel.
  792. Say M if you want the RCU torture tests to build as a module.
  793. Say N if you are unsure.
  794. config RCU_TORTURE_TEST_RUNNABLE
  795. bool "torture tests for RCU runnable by default"
  796. depends on RCU_TORTURE_TEST = y
  797. default n
  798. help
  799. This option provides a way to build the RCU torture tests
  800. directly into the kernel without them starting up at boot
  801. time. You can use /proc/sys/kernel/rcutorture_runnable
  802. to manually override this setting. This /proc file is
  803. available only when the RCU torture tests have been built
  804. into the kernel.
  805. Say Y here if you want the RCU torture tests to start during
  806. boot (you probably don't).
  807. Say N here if you want the RCU torture tests to start only
  808. after being manually enabled via /proc.
  809. config RCU_CPU_STALL_TIMEOUT
  810. int "RCU CPU stall timeout in seconds"
  811. depends on TREE_RCU || TREE_PREEMPT_RCU
  812. range 3 300
  813. default 60
  814. help
  815. If a given RCU grace period extends more than the specified
  816. number of seconds, a CPU stall warning is printed. If the
  817. RCU grace period persists, additional CPU stall warnings are
  818. printed at more widely spaced intervals.
  819. config RCU_CPU_STALL_VERBOSE
  820. bool "Print additional per-task information for RCU_CPU_STALL_DETECTOR"
  821. depends on TREE_PREEMPT_RCU
  822. default y
  823. help
  824. This option causes RCU to printk detailed per-task information
  825. for any tasks that are stalling the current RCU grace period.
  826. Say N if you are unsure.
  827. Say Y if you want to enable such checks.
  828. config RCU_CPU_STALL_INFO
  829. bool "Print additional diagnostics on RCU CPU stall"
  830. depends on (TREE_RCU || TREE_PREEMPT_RCU) && DEBUG_KERNEL
  831. default n
  832. help
  833. For each stalled CPU that is aware of the current RCU grace
  834. period, print out additional per-CPU diagnostic information
  835. regarding scheduling-clock ticks, idle state, and,
  836. for RCU_FAST_NO_HZ kernels, idle-entry state.
  837. Say N if you are unsure.
  838. Say Y if you want to enable such diagnostics.
  839. config RCU_TRACE
  840. bool "Enable tracing for RCU"
  841. depends on DEBUG_KERNEL
  842. help
  843. This option provides tracing in RCU which presents stats
  844. in debugfs for debugging RCU implementation.
  845. Say Y here if you want to enable RCU tracing
  846. Say N if you are unsure.
  847. config KPROBES_SANITY_TEST
  848. bool "Kprobes sanity tests"
  849. depends on DEBUG_KERNEL
  850. depends on KPROBES
  851. default n
  852. help
  853. This option provides for testing basic kprobes functionality on
  854. boot. A sample kprobe, jprobe and kretprobe are inserted and
  855. verified for functionality.
  856. Say N if you are unsure.
  857. config BACKTRACE_SELF_TEST
  858. tristate "Self test for the backtrace code"
  859. depends on DEBUG_KERNEL
  860. default n
  861. help
  862. This option provides a kernel module that can be used to test
  863. the kernel stack backtrace code. This option is not useful
  864. for distributions or general kernels, but only for kernel
  865. developers working on architecture code.
  866. Note that if you want to also test saved backtraces, you will
  867. have to enable STACKTRACE as well.
  868. Say N if you are unsure.
  869. config DEBUG_BLOCK_EXT_DEVT
  870. bool "Force extended block device numbers and spread them"
  871. depends on DEBUG_KERNEL
  872. depends on BLOCK
  873. default n
  874. help
  875. BIG FAT WARNING: ENABLING THIS OPTION MIGHT BREAK BOOTING ON
  876. SOME DISTRIBUTIONS. DO NOT ENABLE THIS UNLESS YOU KNOW WHAT
  877. YOU ARE DOING. Distros, please enable this and fix whatever
  878. is broken.
  879. Conventionally, block device numbers are allocated from
  880. predetermined contiguous area. However, extended block area
  881. may introduce non-contiguous block device numbers. This
  882. option forces most block device numbers to be allocated from
  883. the extended space and spreads them to discover kernel or
  884. userland code paths which assume predetermined contiguous
  885. device number allocation.
  886. Note that turning on this debug option shuffles all the
  887. device numbers for all IDE and SCSI devices including libata
  888. ones, so root partition specified using device number
  889. directly (via rdev or root=MAJ:MIN) won't work anymore.
  890. Textual device names (root=/dev/sdXn) will continue to work.
  891. Say N if you are unsure.
  892. config DEBUG_FORCE_WEAK_PER_CPU
  893. bool "Force weak per-cpu definitions"
  894. depends on DEBUG_KERNEL
  895. help
  896. s390 and alpha require percpu variables in modules to be
  897. defined weak to work around addressing range issue which
  898. puts the following two restrictions on percpu variable
  899. definitions.
  900. 1. percpu symbols must be unique whether static or not
  901. 2. percpu variables can't be defined inside a function
  902. To ensure that generic code follows the above rules, this
  903. option forces all percpu variables to be defined as weak.
  904. config DEBUG_PER_CPU_MAPS
  905. bool "Debug access to per_cpu maps"
  906. depends on DEBUG_KERNEL
  907. depends on SMP
  908. help
  909. Say Y to verify that the per_cpu map being accessed has
  910. been set up. This adds a fair amount of code to kernel memory
  911. and decreases performance.
  912. Say N if unsure.
  913. config LKDTM
  914. tristate "Linux Kernel Dump Test Tool Module"
  915. depends on DEBUG_FS
  916. depends on BLOCK
  917. default n
  918. help
  919. This module enables testing of the different dumping mechanisms by
  920. inducing system failures at predefined crash points.
  921. If you don't need it: say N
  922. Choose M here to compile this code as a module. The module will be
  923. called lkdtm.
  924. Documentation on how to use the module can be found in
  925. Documentation/fault-injection/provoke-crashes.txt
  926. config NOTIFIER_ERROR_INJECTION
  927. tristate "Notifier error injection"
  928. depends on DEBUG_KERNEL
  929. select DEBUG_FS
  930. help
  931. This option provides the ability to inject artifical errors to
  932. specified notifier chain callbacks. It is useful to test the error
  933. handling of notifier call chain failures.
  934. Say N if unsure.
  935. config CPU_NOTIFIER_ERROR_INJECT
  936. tristate "CPU notifier error injection module"
  937. depends on HOTPLUG_CPU && NOTIFIER_ERROR_INJECTION
  938. help
  939. This option provides a kernel module that can be used to test
  940. the error handling of the cpu notifiers by injecting artifical
  941. errors to CPU notifier chain callbacks. It is controlled through
  942. debugfs interface under /sys/kernel/debug/notifier-error-inject/cpu
  943. If the notifier call chain should be failed with some events
  944. notified, write the error code to "actions/<notifier event>/error".
  945. Example: Inject CPU offline error (-1 == -EPERM)
  946. # cd /sys/kernel/debug/notifier-error-inject/cpu
  947. # echo -1 > actions/CPU_DOWN_PREPARE/error
  948. # echo 0 > /sys/devices/system/cpu/cpu1/online
  949. bash: echo: write error: Operation not permitted
  950. To compile this code as a module, choose M here: the module will
  951. be called cpu-notifier-error-inject.
  952. If unsure, say N.
  953. config PM_NOTIFIER_ERROR_INJECT
  954. tristate "PM notifier error injection module"
  955. depends on PM && NOTIFIER_ERROR_INJECTION
  956. default m if PM_DEBUG
  957. help
  958. This option provides the ability to inject artifical errors to
  959. PM notifier chain callbacks. It is controlled through debugfs
  960. interface /sys/kernel/debug/notifier-error-inject/pm
  961. If the notifier call chain should be failed with some events
  962. notified, write the error code to "actions/<notifier event>/error".
  963. Example: Inject PM suspend error (-12 = -ENOMEM)
  964. # cd /sys/kernel/debug/notifier-error-inject/pm/
  965. # echo -12 > actions/PM_SUSPEND_PREPARE/error
  966. # echo mem > /sys/power/state
  967. bash: echo: write error: Cannot allocate memory
  968. To compile this code as a module, choose M here: the module will
  969. be called pm-notifier-error-inject.
  970. If unsure, say N.
  971. config MEMORY_NOTIFIER_ERROR_INJECT
  972. tristate "Memory hotplug notifier error injection module"
  973. depends on MEMORY_HOTPLUG_SPARSE && NOTIFIER_ERROR_INJECTION
  974. help
  975. This option provides the ability to inject artifical errors to
  976. memory hotplug notifier chain callbacks. It is controlled through
  977. debugfs interface under /sys/kernel/debug/notifier-error-inject/memory
  978. If the notifier call chain should be failed with some events
  979. notified, write the error code to "actions/<notifier event>/error".
  980. Example: Inject memory hotplug offline error (-12 == -ENOMEM)
  981. # cd /sys/kernel/debug/notifier-error-inject/memory
  982. # echo -12 > actions/MEM_GOING_OFFLINE/error
  983. # echo offline > /sys/devices/system/memory/memoryXXX/state
  984. bash: echo: write error: Cannot allocate memory
  985. To compile this code as a module, choose M here: the module will
  986. be called pSeries-reconfig-notifier-error-inject.
  987. If unsure, say N.
  988. config PSERIES_RECONFIG_NOTIFIER_ERROR_INJECT
  989. tristate "pSeries reconfig notifier error injection module"
  990. depends on PPC_PSERIES && NOTIFIER_ERROR_INJECTION
  991. help
  992. This option provides the ability to inject artifical errors to
  993. pSeries reconfig notifier chain callbacks. It is controlled
  994. through debugfs interface under
  995. /sys/kernel/debug/notifier-error-inject/pSeries-reconfig/
  996. If the notifier call chain should be failed with some events
  997. notified, write the error code to "actions/<notifier event>/error".
  998. To compile this code as a module, choose M here: the module will
  999. be called memory-notifier-error-inject.
  1000. If unsure, say N.
  1001. config FAULT_INJECTION
  1002. bool "Fault-injection framework"
  1003. depends on DEBUG_KERNEL
  1004. help
  1005. Provide fault-injection framework.
  1006. For more details, see Documentation/fault-injection/.
  1007. config FAILSLAB
  1008. bool "Fault-injection capability for kmalloc"
  1009. depends on FAULT_INJECTION
  1010. depends on SLAB || SLUB
  1011. help
  1012. Provide fault-injection capability for kmalloc.
  1013. config FAIL_PAGE_ALLOC
  1014. bool "Fault-injection capabilitiy for alloc_pages()"
  1015. depends on FAULT_INJECTION
  1016. help
  1017. Provide fault-injection capability for alloc_pages().
  1018. config FAIL_MAKE_REQUEST
  1019. bool "Fault-injection capability for disk IO"
  1020. depends on FAULT_INJECTION && BLOCK
  1021. help
  1022. Provide fault-injection capability for disk IO.
  1023. config FAIL_IO_TIMEOUT
  1024. bool "Fault-injection capability for faking disk interrupts"
  1025. depends on FAULT_INJECTION && BLOCK
  1026. help
  1027. Provide fault-injection capability on end IO handling. This
  1028. will make the block layer "forget" an interrupt as configured,
  1029. thus exercising the error handling.
  1030. Only works with drivers that use the generic timeout handling,
  1031. for others it wont do anything.
  1032. config FAIL_MMC_REQUEST
  1033. bool "Fault-injection capability for MMC IO"
  1034. select DEBUG_FS
  1035. depends on FAULT_INJECTION && MMC
  1036. help
  1037. Provide fault-injection capability for MMC IO.
  1038. This will make the mmc core return data errors. This is
  1039. useful to test the error handling in the mmc block device
  1040. and to test how the mmc host driver handles retries from
  1041. the block device.
  1042. config FAULT_INJECTION_DEBUG_FS
  1043. bool "Debugfs entries for fault-injection capabilities"
  1044. depends on FAULT_INJECTION && SYSFS && DEBUG_FS
  1045. help
  1046. Enable configuration of fault-injection capabilities via debugfs.
  1047. config FAULT_INJECTION_STACKTRACE_FILTER
  1048. bool "stacktrace filter for fault-injection capabilities"
  1049. depends on FAULT_INJECTION_DEBUG_FS && STACKTRACE_SUPPORT
  1050. depends on !X86_64
  1051. select STACKTRACE
  1052. select FRAME_POINTER if !PPC && !S390 && !MICROBLAZE && !ARM_UNWIND
  1053. help
  1054. Provide stacktrace filter for fault-injection capabilities
  1055. config LATENCYTOP
  1056. bool "Latency measuring infrastructure"
  1057. depends on HAVE_LATENCYTOP_SUPPORT
  1058. depends on DEBUG_KERNEL
  1059. depends on STACKTRACE_SUPPORT
  1060. depends on PROC_FS
  1061. select FRAME_POINTER if !MIPS && !PPC && !S390 && !MICROBLAZE && !ARM_UNWIND
  1062. select KALLSYMS
  1063. select KALLSYMS_ALL
  1064. select STACKTRACE
  1065. select SCHEDSTATS
  1066. select SCHED_DEBUG
  1067. help
  1068. Enable this option if you want to use the LatencyTOP tool
  1069. to find out which userspace is blocking on what kernel operations.
  1070. source mm/Kconfig.debug
  1071. source kernel/trace/Kconfig
  1072. config PROVIDE_OHCI1394_DMA_INIT
  1073. bool "Remote debugging over FireWire early on boot"
  1074. depends on PCI && X86
  1075. help
  1076. If you want to debug problems which hang or crash the kernel early
  1077. on boot and the crashing machine has a FireWire port, you can use
  1078. this feature to remotely access the memory of the crashed machine
  1079. over FireWire. This employs remote DMA as part of the OHCI1394
  1080. specification which is now the standard for FireWire controllers.
  1081. With remote DMA, you can monitor the printk buffer remotely using
  1082. firescope and access all memory below 4GB using fireproxy from gdb.
  1083. Even controlling a kernel debugger is possible using remote DMA.
  1084. Usage:
  1085. If ohci1394_dma=early is used as boot parameter, it will initialize
  1086. all OHCI1394 controllers which are found in the PCI config space.
  1087. As all changes to the FireWire bus such as enabling and disabling
  1088. devices cause a bus reset and thereby disable remote DMA for all
  1089. devices, be sure to have the cable plugged and FireWire enabled on
  1090. the debugging host before booting the debug target for debugging.
  1091. This code (~1k) is freed after boot. By then, the firewire stack
  1092. in charge of the OHCI-1394 controllers should be used instead.
  1093. See Documentation/debugging-via-ohci1394.txt for more information.
  1094. config FIREWIRE_OHCI_REMOTE_DMA
  1095. bool "Remote debugging over FireWire with firewire-ohci"
  1096. depends on FIREWIRE_OHCI
  1097. help
  1098. This option lets you use the FireWire bus for remote debugging
  1099. with help of the firewire-ohci driver. It enables unfiltered
  1100. remote DMA in firewire-ohci.
  1101. See Documentation/debugging-via-ohci1394.txt for more information.
  1102. If unsure, say N.
  1103. config BUILD_DOCSRC
  1104. bool "Build targets in Documentation/ tree"
  1105. depends on HEADERS_CHECK
  1106. help
  1107. This option attempts to build objects from the source files in the
  1108. kernel Documentation/ tree.
  1109. Say N if you are unsure.
  1110. config DYNAMIC_DEBUG
  1111. bool "Enable dynamic printk() support"
  1112. default n
  1113. depends on PRINTK
  1114. depends on DEBUG_FS
  1115. help
  1116. Compiles debug level messages into the kernel, which would not
  1117. otherwise be available at runtime. These messages can then be
  1118. enabled/disabled based on various levels of scope - per source file,
  1119. function, module, format string, and line number. This mechanism
  1120. implicitly compiles in all pr_debug() and dev_dbg() calls, which
  1121. enlarges the kernel text size by about 2%.
  1122. If a source file is compiled with DEBUG flag set, any
  1123. pr_debug() calls in it are enabled by default, but can be
  1124. disabled at runtime as below. Note that DEBUG flag is
  1125. turned on by many CONFIG_*DEBUG* options.
  1126. Usage:
  1127. Dynamic debugging is controlled via the 'dynamic_debug/control' file,
  1128. which is contained in the 'debugfs' filesystem. Thus, the debugfs
  1129. filesystem must first be mounted before making use of this feature.
  1130. We refer the control file as: <debugfs>/dynamic_debug/control. This
  1131. file contains a list of the debug statements that can be enabled. The
  1132. format for each line of the file is:
  1133. filename:lineno [module]function flags format
  1134. filename : source file of the debug statement
  1135. lineno : line number of the debug statement
  1136. module : module that contains the debug statement
  1137. function : function that contains the debug statement
  1138. flags : '=p' means the line is turned 'on' for printing
  1139. format : the format used for the debug statement
  1140. From a live system:
  1141. nullarbor:~ # cat <debugfs>/dynamic_debug/control
  1142. # filename:lineno [module]function flags format
  1143. fs/aio.c:222 [aio]__put_ioctx =_ "__put_ioctx:\040freeing\040%p\012"
  1144. fs/aio.c:248 [aio]ioctx_alloc =_ "ENOMEM:\040nr_events\040too\040high\012"
  1145. fs/aio.c:1770 [aio]sys_io_cancel =_ "calling\040cancel\012"
  1146. Example usage:
  1147. // enable the message at line 1603 of file svcsock.c
  1148. nullarbor:~ # echo -n 'file svcsock.c line 1603 +p' >
  1149. <debugfs>/dynamic_debug/control
  1150. // enable all the messages in file svcsock.c
  1151. nullarbor:~ # echo -n 'file svcsock.c +p' >
  1152. <debugfs>/dynamic_debug/control
  1153. // enable all the messages in the NFS server module
  1154. nullarbor:~ # echo -n 'module nfsd +p' >
  1155. <debugfs>/dynamic_debug/control
  1156. // enable all 12 messages in the function svc_process()
  1157. nullarbor:~ # echo -n 'func svc_process +p' >
  1158. <debugfs>/dynamic_debug/control
  1159. // disable all 12 messages in the function svc_process()
  1160. nullarbor:~ # echo -n 'func svc_process -p' >
  1161. <debugfs>/dynamic_debug/control
  1162. See Documentation/dynamic-debug-howto.txt for additional information.
  1163. config DMA_API_DEBUG
  1164. bool "Enable debugging of DMA-API usage"
  1165. depends on HAVE_DMA_API_DEBUG
  1166. help
  1167. Enable this option to debug the use of the DMA API by device drivers.
  1168. With this option you will be able to detect common bugs in device
  1169. drivers like double-freeing of DMA mappings or freeing mappings that
  1170. were never allocated.
  1171. This option causes a performance degredation. Use only if you want
  1172. to debug device drivers. If unsure, say N.
  1173. config ATOMIC64_SELFTEST
  1174. bool "Perform an atomic64_t self-test at boot"
  1175. help
  1176. Enable this option to test the atomic64_t functions at boot.
  1177. If unsure, say N.
  1178. config ASYNC_RAID6_TEST
  1179. tristate "Self test for hardware accelerated raid6 recovery"
  1180. depends on ASYNC_RAID6_RECOV
  1181. select ASYNC_MEMCPY
  1182. ---help---
  1183. This is a one-shot self test that permutes through the
  1184. recovery of all the possible two disk failure scenarios for a
  1185. N-disk array. Recovery is performed with the asynchronous
  1186. raid6 recovery routines, and will optionally use an offload
  1187. engine if one is available.
  1188. If unsure, say N.
  1189. source "samples/Kconfig"
  1190. source "lib/Kconfig.kgdb"
  1191. source "lib/Kconfig.kmemcheck"
  1192. config TEST_KSTRTOX
  1193. tristate "Test kstrto*() family of functions at runtime"