1miocack(9F)              Kernel Functions for Drivers              miocack(9F)
2
3
4

NAME

6       miocack - Positively acknowledge an M_IOCTL message
7

SYNOPSIS

9       #include <sys/stream.h>
10       #include <sys/strsun.h>
11
12
13
14       void miocack(queue_t *wq, mblk_t *mp, intcount, int rval);
15
16

INTERFACE LEVEL

18       Solaris DDI specific (Solaris DDI).
19

PARAMETERS

21       wq       Write  queue  associated  with  the  read  queue  to  send the
22                M_IOCACK on.
23
24
25       mp       M_IOCTL message.
26
27
28       count    Value to set the ioc_count of the iocblk(9S) to.
29
30
31       rval     Value to set the ioc_rval of the iocblk(9S) to.
32
33

DESCRIPTION

35       The miocack() function converts an M_IOCTL message into a M_IOCACK mes‐
36       sage and sends the resulting message upstream.
37
38
39       To convert the message, miocack() changes the message type to M_IOCACK,
40       sets the 'ioc_count' and 'ioc_rval' members of the  iocblk(9S)  associ‐
41       ated with mp to the passed-in values, and clears the 'ioc_error' field.
42       If the caller specifies a non-zero value for count, it is expected that
43       the  caller  has  already  set 'mp->b_cont' field to point to a message
44       block with a length of at least count bytes.
45
46
47       Callers that only need to perform the message conversion,  or  need  to
48       perform additional steps between the conversion and the      sending of
49       the M_IOCACK should use mioc2ack(9F).
50

RETURN VALUES

52       None.
53

CONTEXT

55       This function can be called from user, kernel or interrupt context.
56

NOTES

58       Callers must not hold any locks across a miocack() that can be acquired
59       as part of put(9E) processing.
60

SEE ALSO

62       mioc2ack(9F), put(9E), iocblk(9S)
63
64
65       STREAMS Programming Guide
66
67
68
69SunOS 5.11                        9 June 2004                      miocack(9F)
Impressum