Revert "ecryptfs: forbid opening files without mmap handler"
[linux-2.6-block.git] / arch / blackfin / Kconfig.debug
CommitLineData
74ce8322
MF
1menu "Kernel hacking"
2
3source "lib/Kconfig.debug"
4
9f06c38f
RG
5config DEBUG_VERBOSE
6 bool "Verbose fault messages"
7 default y
8 select PRINTK
9 help
10 When a program crashes due to an exception, or the kernel detects
11 an internal error, the kernel can print a not so brief message
12 explaining what the problem was. This debugging information is
13 useful to developers and kernel hackers when tracking down problems,
14 but mostly meaningless to other people. This is always helpful for
15 debugging but serves no purpose on a production system.
16 Most people should say N here.
17
74ce8322 18config DEBUG_MMRS
73ecfcf9 19 tristate "Generate Blackfin MMR tree"
74ce8322
MF
20 select DEBUG_FS
21 help
22 Create a tree of Blackfin MMRs via the debugfs tree. If
23 you enable this, you will find all MMRs laid out in the
24 /sys/kernel/debug/blackfin/ directory where you can read/write
25 MMRs directly from userspace. This is obviously just a debug
26 feature.
27
28config DEBUG_HWERR
29 bool "Hardware error interrupt debugging"
30 depends on DEBUG_KERNEL
31 help
32 When enabled, the hardware error interrupt is never disabled, and
33 will happen immediately when an error condition occurs. This comes
34 at a slight cost in code size, but is necessary if you are getting
35 hardware error interrupts and need to know where they are coming
36 from.
37
b9a3899d
RG
38config EXACT_HWERR
39 bool "Try to make Hardware errors exact"
40 depends on DEBUG_HWERR
41 help
42 By default, the Blackfin hardware errors are not exact - the error
43 be reported multiple cycles after the error happens. This delay
44 can cause the wrong application, or even the kernel to receive a
45 signal to be killed. If you are getting HW errors in your system,
25985edc 46 try turning this on to ensure they are at least coming from the
b9a3899d
RG
47 proper thread.
48
49 On production systems, it is safe (and a small optimization) to say N.
50
0c7a6b21
RG
51config DEBUG_DOUBLEFAULT
52 bool "Debug Double Faults"
53 default n
54 help
55 If an exception is caused while executing code within the exception
56 handler, the NMI handler, the reset vector, or in emulator mode,
57 a double fault occurs. On the Blackfin, this is a unrecoverable
58 event. You have two options:
59 - RESET exactly when double fault occurs. The excepting
60 instruction address is stored in RETX, where the next kernel
61 boot will print it out.
62 - Print debug message. This is much more error prone, although
63 easier to handle. It is error prone since:
64 - The excepting instruction is not committed.
65 - All writebacks from the instruction are prevented.
66 - The generated exception is not taken.
67 - The EXCAUSE field is updated with an unrecoverable event
68 The only way to check this is to see if EXCAUSE contains the
69 unrecoverable event value at every exception return. By selecting
70 this option, you are skipping over the faulting instruction, and
71 hoping things stay together enough to print out a debug message.
72
73 This does add a little kernel code, but is the only method to debug
74 double faults - if unsure say "Y"
75
76choice
77 prompt "Double Fault Failure Method"
78 default DEBUG_DOUBLEFAULT_PRINT
79 depends on DEBUG_DOUBLEFAULT
80
81config DEBUG_DOUBLEFAULT_PRINT
82 bool "Print"
83
84config DEBUG_DOUBLEFAULT_RESET
85 bool "Reset"
86
87endchoice
88
74ce8322
MF
89config DEBUG_HUNT_FOR_ZERO
90 bool "Catch NULL pointer reads/writes"
91 default y
92 help
93 Say Y here to catch reads/writes to anywhere in the memory range
94 from 0x0000 - 0x0FFF (the first 4k) of memory. This is useful in
95 catching common programming errors such as NULL pointer dereferences.
96
97 Misbehaving applications will be killed (generate a SEGV) while the
98 kernel will trigger a panic.
99
100 Enabling this option will take up an extra entry in CPLB table.
101 Otherwise, there is no extra overhead.
102
103config DEBUG_BFIN_HWTRACE_ON
104 bool "Turn on Blackfin's Hardware Trace"
105 default y
106 help
107 All Blackfins include a Trace Unit which stores a history of the last
108 16 changes in program flow taken by the program sequencer. The history
109 allows the user to recreate the program sequencer’s recent path. This
110 can be handy when an application dies - we print out the execution
111 path of how it got to the offending instruction.
112
113 By turning this off, you may save a tiny amount of power.
114
115choice
116 prompt "Omit loop Tracing"
117 default DEBUG_BFIN_HWTRACE_COMPRESSION_OFF
118 depends on DEBUG_BFIN_HWTRACE_ON
119 help
120 The trace buffer can be configured to omit recording of changes in
121 program flow that match either the last entry or one of the last
122 two entries. Omitting one of these entries from the record prevents
123 the trace buffer from overflowing because of any sort of loop (for, do
124 while, etc) in the program.
125
126 Because zero-overhead Hardware loops are not recorded in the trace buffer,
127 this feature can be used to prevent trace overflow from loops that
128 are nested four deep.
129
130config DEBUG_BFIN_HWTRACE_COMPRESSION_OFF
131 bool "Trace all Loops"
132 help
133 The trace buffer records all changes of flow
134
135config DEBUG_BFIN_HWTRACE_COMPRESSION_ONE
136 bool "Compress single-level loops"
137 help
138 The trace buffer does not record single loops - helpful if trace
139 is spinning on a while or do loop.
140
141config DEBUG_BFIN_HWTRACE_COMPRESSION_TWO
142 bool "Compress two-level loops"
143 help
144 The trace buffer does not record loops two levels deep. Helpful if
145 the trace is spinning in a nested loop
146
147endchoice
148
149config DEBUG_BFIN_HWTRACE_COMPRESSION
150 int
151 depends on DEBUG_BFIN_HWTRACE_ON
152 default 0 if DEBUG_BFIN_HWTRACE_COMPRESSION_OFF
153 default 1 if DEBUG_BFIN_HWTRACE_COMPRESSION_ONE
154 default 2 if DEBUG_BFIN_HWTRACE_COMPRESSION_TWO
155
156
157config DEBUG_BFIN_HWTRACE_EXPAND
158 bool "Expand Trace Buffer greater than 16 entries"
159 depends on DEBUG_BFIN_HWTRACE_ON
160 default n
161 help
162 By selecting this option, every time the 16 hardware entries in
163 the Blackfin's HW Trace buffer are full, the kernel will move them
164 into a software buffer, for dumping when there is an issue. This
165 has a great impact on performance, (an interrupt every 16 change of
166 flows) and should normally be turned off, except in those nasty
167 debugging sessions
168
169config DEBUG_BFIN_HWTRACE_EXPAND_LEN
170 int "Size of Trace buffer (in power of 2k)"
171 range 0 4
172 depends on DEBUG_BFIN_HWTRACE_EXPAND
173 default 1
174 help
175 This sets the size of the software buffer that the trace information
176 is kept in.
177 0 for (2^0) 1k, or 256 entries,
178 1 for (2^1) 2k, or 512 entries,
179 2 for (2^2) 4k, or 1024 entries,
180 3 for (2^3) 8k, or 2048 entries,
181 4 for (2^4) 16k, or 4096 entries
182
183config DEBUG_BFIN_NO_KERN_HWTRACE
e60cb8a9 184 bool "Turn off hwtrace in CPLB handlers"
74ce8322 185 depends on DEBUG_BFIN_HWTRACE_ON
e60cb8a9 186 default y
74ce8322 187 help
e60cb8a9 188 The CPLB error handler contains a lot of flow changes which can
74ce8322
MF
189 quickly fill up the hardware trace buffer. When debugging crashes,
190 the hardware trace may indicate that the problem lies in kernel
191 space when in reality an application is buggy.
192
193 Say Y here to disable hardware tracing in some known "jumpy" pieces
194 of code so that the trace buffer will extend further back.
195
196config EARLY_PRINTK
197 bool "Early printk"
198 default n
0cfbb323 199 select SERIAL_CORE_CONSOLE
74ce8322
MF
200 help
201 This option enables special console drivers which allow the kernel
202 to print messages very early in the bootup process.
203
204 This is useful for kernel debugging when your machine crashes very
205 early before the console code is initialized. After enabling this
206 feature, you must add "earlyprintk=serial,uart0,57600" to the
207 command line (bootargs). It is safe to say Y here in all cases, as
208 all of this lives in the init section and is thrown away after the
209 kernel boots completely.
210
60ffdb36
GY
211config NMI_WATCHDOG
212 bool "Enable NMI watchdog to help debugging lockup on SMP"
213 default n
c429886a 214 depends on SMP
60ffdb36
GY
215 help
216 If any CPU in the system does not execute the period local timer
217 interrupt for more than 5 seconds, then the NMI handler dumps debug
218 information. This information can be used to debug the lockup.
219
74ce8322
MF
220config CPLB_INFO
221 bool "Display the CPLB information"
222 help
cf93425d 223 Display the CPLB information via /proc/cplbinfo.
74ce8322
MF
224
225config ACCESS_CHECK
226 bool "Check the user pointer address"
227 default y
228 help
229 Usually the pointer transfer from user space is checked to see if its
230 address is in the kernel space.
231
232 Say N here to disable that check to improve the performance.
233
c40cdb2c
MF
234config BFIN_ISRAM_SELF_TEST
235 bool "isram boot self tests"
236 default n
237 help
238 Run some self tests of the isram driver code at boot.
239
6ce3e9c2
RG
240config BFIN_PSEUDODBG_INSNS
241 bool "Support pseudo debug instructions"
242 default n
243 help
244 This option allows the kernel to emulate some pseudo instructions which
245 allow simulator test cases to be run under Linux with no changes.
246
247 Most people should say N here.
248
72b099ed
SZ
249config BFIN_PM_WAKEUP_TIME_BENCH
250 bool "Display the total time for kernel to resume from power saving mode"
251 default n
252 help
253 Display the total time when kernel resumes normal from standby or
254 suspend to mem mode.
255
74ce8322 256endmenu