File: kdb_rd.man

package info (click to toggle)
kernel-patch-kdb 2.1-3-1
  • links: PTS
  • area: main
  • in suites: woody
  • size: 4,900 kB
  • ctags: 421
  • sloc: ansic: 3,819; makefile: 74
file content (81 lines) | stat: -rw-r--r-- 2,645 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
.TH RD 1 "17 January 2002"
.SH NAME
rd, rm\- Register manipulation commands
.SH SYNOPSIS
rd [c|d|u]
.LP
rm \fIregister-name\fP \fInew-contents\fP
.LP
ef <address>
.SH DESCRIPTION
The
.B rd 
command is used to display the contents of processor registers.
Without any arguments, the rd command displays the contents of
the general register set at the point at which the kernel debugger
was entered.
.P
With the 'c' argument, the processor control registers
%cr0, %cr1, %cr2 and %cr4 are displayed, while with the 'd' argument
the processor debug registers are displayed.  If the 'u' argument
is supplied, the registers for the current task as of the last
time the current task entered the kernel are displayed.
.P
On ix86, the
.B rm
command allows modification of a register.  The following 
register names are valid:  \fB%eax\fP, \fB%ebx\fP, \fB%ecx\fP,
\fB%edx\fP, \fB%esi\fP, \fB%edi\fP, \fB%esp\fP, \fB%eip\fP, 
and \fB%ebp\fP.   Note that if two '%' symbols are used 
consecutively, the register set displayed by the 'u' argument
to the \fBrd\fP command is modified.
.P
The debug registers, \fBdr0\fP through \fBdr3\fP and both
\fBdr6\fP and \fBdr7\fP can also be modified with the \fBrm\fP
command.
.P
On sparc64, the valid registers are named \fB%g0\fP through
\fB%g7\fP, \fB%l0\fP through \fB%l7\fP, \fB%o0\fP through
\fB%o7\fP, and \fB%i0\fP through \fB%i7\fP, with the exceptions
that \fB%o6\fP is called \fB%sp\fP and that \fB%i6\fP is called
\fB%fp\fP. The registers \fB%tstate\fP, \fB%tpc\fP, \fB%tnpc\fP,
\fB%y\fP, and \fB%fprs\fP provide state information at the time
the system entered kdb. Additionally, when viewing registers, two
convenience names are provided: \fB%&regs\fP shows the
address on the stack of the current registers, and \fB%csp\fP
shows the current stack pointer within kdb itself.
.P
The
.B ef
command displays an exception frame at the specified address.
.SH LIMITATIONS
Currently the \fBrm\fP command will not allow modification of the
control registers.
.P
Currently neither the \fBrd\fP command nor the \fBrm\fP command will
display or modify the model specific registers on the Pentium
and Pentium Pro families.
.SH ENVIRONMENT
None.
.SH SMP CONSIDERATIONS
None.
.SH EXAMPLES
.TP 8
rd
Display general register set.

.TP 8
rm %eax 0
Set the contents of \fB%eax\fP to zero.  This will be the
value of %eax when kdb returns from the condition which 
invoked it.

.TP 8
rm %%eax 0
Set the value of the \fB%eax\fP register to zero.  This will
be the value the user-mode application will see upon returning
from the kernel.

.TP 8
rm dr0 0xc1287220
Set the value of the \fBdr0\fB register to \f(CW0xc1287220\fP.