STREAMS/UX for the HP 9000 Reference Manual

159
Debugging STREAMS/UX Modules and Drivers
STREAMS/UX Debugging Tool
address. As shown above, strdb also reports that sp's read queue address is
0x00605e00. The next two words are pointers to messages being saved until
timeouts expire. The first word is the head of the message queue. Its value
is 0x00000000. The second word is the tail. Its value is 0x005fb600. The
user does not understand how the head of the list can be 0 and the tail
non-zero. The user decides to ask strdb to format the message on the tail of
the queue using the :x command. First, the user enters the :x ? command to
see the names of the structures that strdb formats.
:x ?
known data structure descriptions...
streamtab
msgb
a__datab
datab
free_rtn
queue
qband
qinit
module_info
module_stat
strapush
ioc_pad
iocblk
copyreq
copyresp
stroptions
-- Hit any key to continue --
The user sees that strdb formats msgb, a message block. The user can
double check that this is the correct structure name by looking in the
sys/stream.h include file. Then, the user enters the :x command to see the
message block.
:x msgb 0x005fb600
struct msgb 0x5fb600 S:6
b_next = 0x5fb700
b_prev = 0x0
b_cont = 0x5fb680
b_rptr = 0x599400
b_wptr = 0x5996ac
b_datap = 0x5fb640
b_band = 0
b_pad1 = 00
b_flag = 0x0
b_pad2 = 0