]>
Commit | Line | Data |
---|---|---|
91447636 A |
1 | .\" Copyright (c) 1999 Softweyr LLC. |
2 | .\" All rights reserved. | |
3 | .\" | |
4 | .\" Redistribution and use in source and binary forms, with or without | |
5 | .\" modification, are permitted provided that the following conditions | |
6 | .\" are met: | |
7 | .\" 1. Redistributions of source code must retain the above copyright | |
8 | .\" notice, this list of conditions and the following disclaimer. | |
9 | .\" 2. Redistributions in binary form must reproduce the above copyright | |
10 | .\" notice, this list of conditions and the following disclaimer in the | |
11 | .\" documentation and/or other materials provided with the distribution. | |
12 | .\" | |
13 | .\" THIS SOFTWARE IS PROVIDED BY Softweyr LLC AND CONTRIBUTORS ``AS IS'' AND | |
14 | .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | |
15 | .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE | |
16 | .\" ARE DISCLAIMED. IN NO EVENT SHALL Softweyr LLC OR CONTRIBUTORS BE LIABLE | |
17 | .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | |
18 | .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS | |
19 | .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | |
20 | .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT | |
21 | .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | |
22 | .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | |
23 | .\" SUCH DAMAGE. | |
24 | .\" | |
25 | .\" $FreeBSD: src/lib/libc/sys/aio_return.2,v 1.17 2003/01/13 10:37:11 tjr Exp $ | |
26 | .\" | |
27 | .Dd June 2, 1999 | |
28 | .Dt AIO_RETURN 2 | |
29 | .Os | |
30 | .Sh NAME | |
31 | .Nm aio_return | |
32 | .Nd retrieve return status of asynchronous I/O operation (REALTIME) | |
33 | .Sh LIBRARY | |
34 | .Lb libc | |
35 | .Sh SYNOPSIS | |
36 | .In aio.h | |
2d21ac55 A |
37 | .Ft ssize_t |
38 | .Fo aio_return | |
39 | .Fa "struct aiocb *aiocbp" | |
40 | .Fc | |
91447636 A |
41 | .Sh DESCRIPTION |
42 | The | |
43 | .Fn aio_return | |
44 | system call returns the final status of the asynchronous I/O request | |
45 | associated with the structure pointed to by | |
2d21ac55 | 46 | .Fa aiocbp . |
91447636 A |
47 | .Pp |
48 | The | |
49 | .Fn aio_return | |
50 | system call | |
51 | should only be called once, to obtain the final status of an asynchronous | |
52 | I/O operation once | |
53 | .Xr aio_error 2 | |
54 | returns something other than | |
55 | .Er EINPROGRESS . | |
56 | .Sh RETURN VALUES | |
2d21ac55 A |
57 | If the asynchronous I/O request has completed, |
58 | the status is returned as described in | |
91447636 A |
59 | .Xr read 2 , |
60 | .Xr write 2 , | |
61 | or | |
62 | .Xr fsync 2 . | |
63 | On failure, | |
64 | .Fn aio_return | |
65 | returns | |
66 | .Dv -1 | |
67 | and sets | |
68 | .Dv errno | |
69 | to indicate the error condition. | |
70 | .Sh ERRORS | |
71 | The | |
72 | .Fn aio_return | |
73 | system call will fail if: | |
74 | .Bl -tag -width Er | |
2d21ac55 | 75 | .\" ========== |
91447636 A |
76 | .It Bq Er EINVAL |
77 | The | |
2d21ac55 | 78 | .Fa aiocbp |
91447636 A |
79 | argument |
80 | does not reference an outstanding asynchronous I/O request. | |
81 | .El | |
2d21ac55 A |
82 | .Sh LEGACY SYNOPSIS |
83 | .Fd #include <aio.h> | |
84 | .Pp | |
85 | .Ft int | |
86 | .br | |
87 | .Fo aio_return | |
88 | .Fa "struct aiocb *aiocbp" | |
89 | .Fc ; | |
90 | .Pp | |
91 | The type of the return value has changed. | |
91447636 A |
92 | .Sh SEE ALSO |
93 | .Xr aio_cancel 2 , | |
94 | .Xr aio_error 2 , | |
95 | .Xr aio_suspend 2 , | |
96 | .Xr aio_write 2 , | |
97 | .Xr fsync 2 , | |
98 | .Xr read 2 , | |
99 | .Xr write 2 , | |
2d21ac55 A |
100 | .Xr aio 4 , |
101 | .Xr compat 5 | |
91447636 A |
102 | .Sh STANDARDS |
103 | The | |
104 | .Fn aio_return | |
105 | system call | |
106 | is expected to conform to the | |
107 | .St -p1003.1 | |
108 | standard. | |
109 | .Sh HISTORY | |
110 | The | |
111 | .Fn aio_return | |
112 | system call first appeared in | |
113 | .Fx 3.0 . | |
114 | .Sh AUTHORS | |
115 | This | |
116 | manual page was written by | |
117 | .An Wes Peters Aq wes@softweyr.com . |