aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/DocBook/kgdb.tmpl
diff options
context:
space:
mode:
Diffstat (limited to 'Documentation/DocBook/kgdb.tmpl')
-rw-r--r--Documentation/DocBook/kgdb.tmpl28
1 files changed, 11 insertions, 17 deletions
diff --git a/Documentation/DocBook/kgdb.tmpl b/Documentation/DocBook/kgdb.tmpl
index 97618bed4d65..e8acd1f03456 100644
--- a/Documentation/DocBook/kgdb.tmpl
+++ b/Documentation/DocBook/kgdb.tmpl
@@ -72,7 +72,7 @@
72 kgdb is a source level debugger for linux kernel. It is used along 72 kgdb is a source level debugger for linux kernel. It is used along
73 with gdb to debug a linux kernel. The expectation is that gdb can 73 with gdb to debug a linux kernel. The expectation is that gdb can
74 be used to "break in" to the kernel to inspect memory, variables 74 be used to "break in" to the kernel to inspect memory, variables
75 and look through a cal stack information similar to what an 75 and look through call stack information similar to what an
76 application developer would use gdb for. It is possible to place 76 application developer would use gdb for. It is possible to place
77 breakpoints in kernel code and perform some limited execution 77 breakpoints in kernel code and perform some limited execution
78 stepping. 78 stepping.
@@ -84,17 +84,18 @@
84 runs an instance of gdb against the vmlinux file which contains 84 runs an instance of gdb against the vmlinux file which contains
85 the symbols (not boot image such as bzImage, zImage, uImage...). 85 the symbols (not boot image such as bzImage, zImage, uImage...).
86 In gdb the developer specifies the connection parameters and 86 In gdb the developer specifies the connection parameters and
87 connects to kgdb. Depending on which kgdb I/O modules exist in 87 connects to kgdb. The type of connection a developer makes with
88 the kernel for a given architecture, it may be possible to debug 88 gdb depends on the availability of kgdb I/O modules compiled as
89 the test machine's kernel with the development machine using a 89 builtin's or kernel modules in the test machine's kernel.
90 rs232 or ethernet connection.
91 </para> 90 </para>
92 </chapter> 91 </chapter>
93 <chapter id="CompilingAKernel"> 92 <chapter id="CompilingAKernel">
94 <title>Compiling a kernel</title> 93 <title>Compiling a kernel</title>
95 <para> 94 <para>
96 To enable <symbol>CONFIG_KGDB</symbol>, look under the "Kernel debugging" 95 To enable <symbol>CONFIG_KGDB</symbol> you should first turn on
97 and then select "KGDB: kernel debugging with remote gdb". 96 "Prompt for development and/or incomplete code/drivers"
97 (CONFIG_EXPERIMENTAL) in "General setup", then under the
98 "Kernel debugging" select "KGDB: kernel debugging with remote gdb".
98 </para> 99 </para>
99 <para> 100 <para>
100 Next you should choose one of more I/O drivers to interconnect debugging 101 Next you should choose one of more I/O drivers to interconnect debugging
@@ -221,7 +222,7 @@
221 </para> 222 </para>
222 <para> 223 <para>
223 IMPORTANT NOTE: Using this option with kgdb over the console 224 IMPORTANT NOTE: Using this option with kgdb over the console
224 (kgdboc) or kgdb over ethernet (kgdboe) is not supported. 225 (kgdboc) is not supported.
225 </para> 226 </para>
226 </sect1> 227 </sect1>
227 </chapter> 228 </chapter>
@@ -247,18 +248,11 @@
247 (gdb) target remote /dev/ttyS0 248 (gdb) target remote /dev/ttyS0
248 </programlisting> 249 </programlisting>
249 <para> 250 <para>
250 Example (kgdb to a terminal server): 251 Example (kgdb to a terminal server on tcp port 2012):
251 </para> 252 </para>
252 <programlisting> 253 <programlisting>
253 % gdb ./vmlinux 254 % gdb ./vmlinux
254 (gdb) target remote udp:192.168.2.2:6443 255 (gdb) target remote 192.168.2.2:2012
255 </programlisting>
256 <para>
257 Example (kgdb over ethernet):
258 </para>
259 <programlisting>
260 % gdb ./vmlinux
261 (gdb) target remote udp:192.168.2.2:6443
262 </programlisting> 256 </programlisting>
263 <para> 257 <para>
264 Once connected, you can debug a kernel the way you would debug an 258 Once connected, you can debug a kernel the way you would debug an