]> git.ipfire.org Git - thirdparty/man-pages.git/blame - man3/aio_return.3
All pages: Replace the 4th argument to .TH by "Linux man-pages (unreleased)"
[thirdparty/man-pages.git] / man3 / aio_return.3
CommitLineData
fea681da
MK
1.\" Copyright (c) 2003 Andries Brouwer (aeb@cwi.nl)
2.\"
e4a74ca8 3.\" SPDX-License-Identifier: GPL-2.0-or-later
fea681da 4.\"
7bd6328f 5.TH AIO_RETURN 3 2021-03-22 "Linux man-pages (unreleased)" "Linux Programmer's Manual"
fea681da
MK
6.SH NAME
7aio_return \- get return status of asynchronous I/O operation
a42212d0
AC
8.SH LIBRARY
9Real-time library
8fc3b2cf 10.RI ( librt ", " \-lrt )
fea681da 11.SH SYNOPSIS
c7db92b9 12.nf
fea681da 13.B "#include <aio.h>"
68e4db0a 14.PP
fea681da 15.BI "ssize_t aio_return(struct aiocb *" aiocbp );
c7db92b9 16.fi
fea681da
MK
17.SH DESCRIPTION
18The
e511ffb6 19.BR aio_return ()
fea681da
MK
20function returns the final return status for the asynchronous I/O request
21with control block pointed to by
22.IR aiocbp .
2b014d76
MK
23(See
24.BR aio (7)
25for a description of the
26.I aiocb
27structure.)
dd3568a1 28.PP
fea681da 29This function should be called only once for any given request, after
a2ef1094 30.BR aio_error (3)
2f0af33b
MK
31returns something other than
32.BR EINPROGRESS .
47297adb 33.SH RETURN VALUE
fea681da
MK
34If the asynchronous I/O operation has completed, this function returns
35the value that would have been returned in case of a synchronous
898d27b4
MK
36.BR read (2),
37.BR write (2),
aa0da2b9 38.BR fsync (2),
fea681da 39or
898d27b4
MK
40.BR fdatasync (2),
41call.
f6a4078b 42On error, \-1 is returned, and \fIerrno\fP is set to indicate the error.
847e0d88 43.PP
898d27b4
MK
44If the asynchronous I/O operation has not yet completed,
45the return value and effect of
46.BR aio_return ()
47are undefined.
fea681da
MK
48.SH ERRORS
49.TP
50.B EINVAL
51.I aiocbp
52does not point at a control block for an asynchronous I/O request
53of which the return status has not been retrieved yet.
aea038d6
MK
54.TP
55.B ENOSYS
56.BR aio_return ()
57is not implemented.
793514ae
MK
58.SH VERSIONS
59The
60.BR aio_return ()
61function is available since glibc 2.1.
0b0a32b8 62.SH ATTRIBUTES
4bdf6cc9
MK
63For an explanation of the terms used in this section, see
64.BR attributes (7).
c466875e
MK
65.ad l
66.nh
4bdf6cc9
MK
67.TS
68allbox;
c466875e 69lbx lb lb
4bdf6cc9
MK
70l l l.
71Interface Attribute Value
72T{
0b0a32b8 73.BR aio_return ()
4bdf6cc9
MK
74T} Thread safety MT-Safe
75.TE
c466875e
MK
76.hy
77.ad
78.sp 1
3113c7f3 79.SH STANDARDS
793514ae 80POSIX.1-2001, POSIX.1-2008.
a14af333 81.SH EXAMPLES
b44bee16
MK
82See
83.BR aio (7).
47297adb 84.SH SEE ALSO
fea681da
MK
85.BR aio_cancel (3),
86.BR aio_error (3),
87.BR aio_fsync (3),
88.BR aio_read (3),
89.BR aio_suspend (3),
25fa6c3d 90.BR aio_write (3),
cd587df6 91.BR lio_listio (3),
25fa6c3d 92.BR aio (7)