.TH datab "" "" "STREAMS Data Structure"
.PC "Structure for a STREAMS data block"
.B "#include <sys/types.h>"
.B "#include <sys/stream.h>"
.PP
The data-block structure
.B datab
holds the data of a \*(ST message.
The message-block structure
.B msgb
includes a field that points to it.
The kernel allocates a
.B datab
when it creates structures of type
.BR mblk_t .
.PP
The following fields within
.B datab
are available to a driver:
.IP "\fBuchar_t *db_base\fR" 1.3i
The beginning of the data buffer.
Do not alter this field.
.IP "\fBuchar_t *db_lim\fR"
This field points to one byte past the end of the data buffer.
Do not alter this field.
.IP "\fBuchar_t db_ref\fR"
The number of message blocks that share the data buffer.
Only one message block can point to any given data block at any given time;
therefore, if the value of this field is greater than one,
do not change the contents of the data buffer.
Do not alter this field.
.IP "\fBuchar_t db_type\fR"
The type of message within the data buffer.
A driver can change this field \(em but only if field
.B db_ref
equals one, as described above.
.SH "See Also"
.B
DDI/DKI data structures,
free_rtn,
messages,
msgb
.R
.SH Notes
The structure
.B datab
is defined as type
.BR dblk_t .
