3 source "lib/Kconfig.debug"
9 bool "Verbose fault messages"
13 When a program crashes due to an exception, or the kernel detects
14 an internal error, the kernel can print a not so brief message
15 explaining what the problem was. This debugging information is
16 useful to developers and kernel hackers when tracking down problems,
17 but mostly meaningless to other people. This is always helpful for
18 debugging but serves no purpose on a production system.
19 Most people should say N here.
22 bool "Generate Blackfin MMR tree"
25 Create a tree of Blackfin MMRs via the debugfs tree. If
26 you enable this, you will find all MMRs laid out in the
27 /sys/kernel/debug/blackfin/ directory where you can read/write
28 MMRs directly from userspace. This is obviously just a debug
32 bool "Hardware error interrupt debugging"
33 depends on DEBUG_KERNEL
35 When enabled, the hardware error interrupt is never disabled, and
36 will happen immediately when an error condition occurs. This comes
37 at a slight cost in code size, but is necessary if you are getting
38 hardware error interrupts and need to know where they are coming
41 config DEBUG_DOUBLEFAULT
42 bool "Debug Double Faults"
45 If an exception is caused while executing code within the exception
46 handler, the NMI handler, the reset vector, or in emulator mode,
47 a double fault occurs. On the Blackfin, this is a unrecoverable
48 event. You have two options:
49 - RESET exactly when double fault occurs. The excepting
50 instruction address is stored in RETX, where the next kernel
51 boot will print it out.
52 - Print debug message. This is much more error prone, although
53 easier to handle. It is error prone since:
54 - The excepting instruction is not committed.
55 - All writebacks from the instruction are prevented.
56 - The generated exception is not taken.
57 - The EXCAUSE field is updated with an unrecoverable event
58 The only way to check this is to see if EXCAUSE contains the
59 unrecoverable event value at every exception return. By selecting
60 this option, you are skipping over the faulting instruction, and
61 hoping things stay together enough to print out a debug message.
63 This does add a little kernel code, but is the only method to debug
64 double faults - if unsure say "Y"
67 prompt "Double Fault Failure Method"
68 default DEBUG_DOUBLEFAULT_PRINT
69 depends on DEBUG_DOUBLEFAULT
71 config DEBUG_DOUBLEFAULT_PRINT
74 config DEBUG_DOUBLEFAULT_RESET
79 config DEBUG_ICACHE_CHECK
80 bool "Check Instruction cache coherency"
81 depends on DEBUG_KERNEL
82 depends on DEBUG_HWERR
84 Say Y here if you are getting weird unexplained errors. This will
85 ensure that icache is what SDRAM says it should be by doing a
86 byte wise comparison between SDRAM and instruction cache. This
87 also relocates the irq_panic() function to L1 memory, (which is
90 config DEBUG_HUNT_FOR_ZERO
91 bool "Catch NULL pointer reads/writes"
94 Say Y here to catch reads/writes to anywhere in the memory range
95 from 0x0000 - 0x0FFF (the first 4k) of memory. This is useful in
96 catching common programming errors such as NULL pointer dereferences.
98 Misbehaving applications will be killed (generate a SEGV) while the
99 kernel will trigger a panic.
101 Enabling this option will take up an extra entry in CPLB table.
102 Otherwise, there is no extra overhead.
104 config DEBUG_BFIN_HWTRACE_ON
105 bool "Turn on Blackfin's Hardware Trace"
108 All Blackfins include a Trace Unit which stores a history of the last
109 16 changes in program flow taken by the program sequencer. The history
110 allows the user to recreate the program sequencer’s recent path. This
111 can be handy when an application dies - we print out the execution
112 path of how it got to the offending instruction.
114 By turning this off, you may save a tiny amount of power.
117 prompt "Omit loop Tracing"
118 default DEBUG_BFIN_HWTRACE_COMPRESSION_OFF
119 depends on DEBUG_BFIN_HWTRACE_ON
121 The trace buffer can be configured to omit recording of changes in
122 program flow that match either the last entry or one of the last
123 two entries. Omitting one of these entries from the record prevents
124 the trace buffer from overflowing because of any sort of loop (for, do
125 while, etc) in the program.
127 Because zero-overhead Hardware loops are not recorded in the trace buffer,
128 this feature can be used to prevent trace overflow from loops that
129 are nested four deep.
131 config DEBUG_BFIN_HWTRACE_COMPRESSION_OFF
132 bool "Trace all Loops"
134 The trace buffer records all changes of flow
136 config DEBUG_BFIN_HWTRACE_COMPRESSION_ONE
137 bool "Compress single-level loops"
139 The trace buffer does not record single loops - helpful if trace
140 is spinning on a while or do loop.
142 config DEBUG_BFIN_HWTRACE_COMPRESSION_TWO
143 bool "Compress two-level loops"
145 The trace buffer does not record loops two levels deep. Helpful if
146 the trace is spinning in a nested loop
150 config DEBUG_BFIN_HWTRACE_COMPRESSION
152 depends on DEBUG_BFIN_HWTRACE_ON
153 default 0 if DEBUG_BFIN_HWTRACE_COMPRESSION_OFF
154 default 1 if DEBUG_BFIN_HWTRACE_COMPRESSION_ONE
155 default 2 if DEBUG_BFIN_HWTRACE_COMPRESSION_TWO
158 config DEBUG_BFIN_HWTRACE_EXPAND
159 bool "Expand Trace Buffer greater than 16 entries"
160 depends on DEBUG_BFIN_HWTRACE_ON
163 By selecting this option, every time the 16 hardware entries in
164 the Blackfin's HW Trace buffer are full, the kernel will move them
165 into a software buffer, for dumping when there is an issue. This
166 has a great impact on performance, (an interrupt every 16 change of
167 flows) and should normally be turned off, except in those nasty
170 config DEBUG_BFIN_HWTRACE_EXPAND_LEN
171 int "Size of Trace buffer (in power of 2k)"
173 depends on DEBUG_BFIN_HWTRACE_EXPAND
176 This sets the size of the software buffer that the trace information
178 0 for (2^0) 1k, or 256 entries,
179 1 for (2^1) 2k, or 512 entries,
180 2 for (2^2) 4k, or 1024 entries,
181 3 for (2^3) 8k, or 2048 entries,
182 4 for (2^4) 16k, or 4096 entries
184 config DEBUG_BFIN_NO_KERN_HWTRACE
185 bool "Trace user apps (turn off hwtrace in kernel)"
186 depends on DEBUG_BFIN_HWTRACE_ON
189 Some pieces of the kernel contain a lot of flow changes which can
190 quickly fill up the hardware trace buffer. When debugging crashes,
191 the hardware trace may indicate that the problem lies in kernel
192 space when in reality an application is buggy.
194 Say Y here to disable hardware tracing in some known "jumpy" pieces
195 of code so that the trace buffer will extend further back.
200 select SERIAL_CORE_CONSOLE
202 This option enables special console drivers which allow the kernel
203 to print messages very early in the bootup process.
205 This is useful for kernel debugging when your machine crashes very
206 early before the console code is initialized. After enabling this
207 feature, you must add "earlyprintk=serial,uart0,57600" to the
208 command line (bootargs). It is safe to say Y here in all cases, as
209 all of this lives in the init section and is thrown away after the
210 kernel boots completely.
213 bool "Display the CPLB information"
215 Display the CPLB information via /proc/cplbinfo.
218 bool "Check the user pointer address"
221 Usually the pointer transfer from user space is checked to see if its
222 address is in the kernel space.
224 Say N here to disable that check to improve the performance.