Hallo, dies ist ein Test.
PWD: /www/data-lst1/unixsoft/unixsoft/kaempfer/.public_html
Running in File Mode
Relative path: ./../../.././../../../usr/man/man9f/MBLKHEAD.9f
Real path: /usr/share/man/man9f/MBLKHEAD.9f
Zurück
'\" te .\" Copyright (c) 2004, 2020, Oracle and/or its affiliates. .TH MBLKHEAD 9F "9 June 2004" "Oracle Solaris 11.4" "Kernel Functions" .SH NAME MBLKHEAD, MBLKIN, MBLKL, MBLKSIZE, MBLKTAIL \- Message block utility macros .SH SYNOPSIS .LP .nf #include <sys/stream.h> #include <sys/strsun.h> \fBint\fR \fBMBLKHEAD\fR(\fBmblk_t *\fR\fImp\fR); .fi .LP .nf \fBint\fR \fBMBLKTAIL\fR(\fBmblk_t *\fR\fImp\fR); .fi .LP .nf \fBint\fR \fBMBLKSIZE\fR(\fBmblk_t *\fR\fImp\fR); .fi .LP .nf \fBint\fR \fBMBLKL\fR(\fBmblk_t *\fR\fImp\fR); .fi .LP .nf \fBint\fR \fBMBLKIN\fR(\fBmblk_t *\fR\fImp\fR, \fBint\fR \fIoffset\fR, \fBint\fR \fIlen\fR); .fi .SH INTERFACE LEVEL .sp .LP Solaris DDI specific (Solaris DDI). .SH PARAMETERS .sp .ne 2 .mk .na \fB\fImp\fR\fR .ad .RS 10n .rt Message to be examined. .RE .sp .ne 2 .mk .na \fB\fIoffset\fR\fR .ad .RS 10n .rt Offset from \fBmp->b_rptr\fR from which to start examining. .RE .sp .ne 2 .mk .na \fB\fIlen\fR\fR .ad .RS 10n .rt Number of bytes to examine. .RE .SH DESCRIPTION .sp .LP The \fBMBLKHEAD()\fR macro calculates the number of bytes between the first byte and the first unread byte of the message block, that is: \fBmp->b_rptr - mp->b_datap->db_base\fR. .sp .LP The \fBMBLKTAIL()\fR macro calculates the number of bytes between the first unwritten byte and the last byte of the message block, that is: \fBmp->b_datap->db_lim - mp->b_wptr\fR. .sp .LP The \fBMBLKSIZE()\fR macros calculates the total size of the message block, that is: \fBmp->b_datap->db_lim - mp->b_datap->db_base\fR. .sp .LP The \fBMBLKL()\fR macro calculates the length of the message block, that is: \fBmp->b_wptr - mp->b_rptr\fR. .sp .LP The \fBMBLKIN()\fR macro checks whether the byte range specified by \fIoffset\fR and \fIlen\fR resides entirely within the message block. .SH RETURN VALUES .sp .LP The \fBMBLKHEAD()\fR, \fBMBLKTAIL()\fR, \fBMBLKL()\fR and \fBMBLKSIZE()\fR functions all return the appropriate byte count, as specified above. \fBMBLKIN()\fR returns non-zero if the check succeeds, or zero if it fails. .SH CONTEXT .sp .LP These functions can be called from user, kernel or interrupt context. .SH NOTES .sp .LP These macros may evaluate any of their arguments more than once. This precludes passing arguments with side effects. .sp .LP These macros assume the message itself is well formed, that is: \fBmp->b_datap->db_base <= mp->b_rptr <= mp->b_wptr <= mp->b_datap->db_lim\fR. .SH SEE ALSO .sp .LP \fBmsgb\fR(9S) .sp .LP \fISTREAMS Programming Guide\fR