1
0
Files
irix-657m-src/eoe/man/manD/putctl1.d3
2022-09-29 17:59:04 +03:00

58 lines
1.6 KiB
Plaintext

.if n .pH ddi.rm/d3/gen/putctl1 @(#)putctl1 43.11 of 11/30/92
.\" Copyright 1992, 1991 UNIX System Laboratories, Inc.
.TH putctl1 D3
.IX "\f4putctl1\fP(D3)"
.SH NAME
\f4putctl1\f1 \- send a control message with a one-byte parameter to a queue
.SH SYNOPSIS
.nf
.na
.ft 4
#include <sys/stream.h>
#include <sys/ddi.h>
.sp 0.4
int putctl1(queue_t *\f2q\fP, int \f2type\fP, int \f2param\fP);
.ft 1
.ad
.fi
.SS Arguments
.RS 0
.IP "\f2q\f1" 10n
Pointer to the queue to which the message is to be sent.
.IP "\f2type\f1" 10n
Message type (must be a control type).
.IP "\f2param\f1" 10n
One-byte parameter.
.RE
.SH DESCRIPTION
\f4putctl1\f1, like \f4putctl\f1(D3), tests the \f2type\f1
argument to make sure a data type has
not been specified, and attempts to allocate a message block.
The \f2param\f1
parameter can be used, for example, to
specify the signal number
when an \f4M_PCSIG\f1 message is being sent.
\f4putctl1\f1 fails if \f4type\f1 is \f4M_DATA\f1, \f4M_PROTO\f1,
or \f4M_PCPROTO\f1, or if a message block cannot be allocated.
If successful, \f4putctl1\f1 calls the \f4put\f1(D2) routine of the queue
pointed to by \f2q\f1, passing it the allocated message.
.SS "Return Values"
On success, 1 is returned.
Otherwise, if \f2type\f1 is a
data type, or if a message block cannot be allocated,
0 is returned.
.SS Level
Base or Interrupt.
.SS "Synchronization Constraints"
Does not sleep.
.P
Driver-defined basic locks, read/write locks, and sleep locks
may not be held across calls to this function.
.SS Examples
See \f4putctl\f1(D3) for an example of \f4putctl1\f1.
.SH REFERENCES
.na
\f4put\fP(D2),
\f4putctl\fP(D3)
.ad