1 .\" Copyright (C) 2003 Free Software Foundation, Inc.
3 .\" %%%LICENSE_START(GPL_NOVERSION_ONELINE)
4 .\" This file is distributed according to the GNU General Public License.
7 .TH IO_DESTROY 2 2021-03-22 "Linux" "Linux Programmer's Manual"
9 io_destroy \- destroy an asynchronous I/O context
12 .BR "#include <linux/aio_abi.h>" " /* Definition of " aio_context_t " */"
13 .BR "#include <sys/syscall.h>" " /* Definition of " SYS_* " constants */"
14 .B #include <unistd.h>
16 .BI "int syscall(SYS_io_destroy, aio_context_t " ctx_id );
20 glibc provides no wrapper for
22 necessitating the use of
26 this page describes the raw Linux system call interface.
27 The wrapper function provided by
29 uses a different type for the
37 will attempt to cancel all outstanding asynchronous I/O operations against
39 will block on the completion of all operations
40 that could not be canceled, and will destroy the
46 For the failure return, see NOTES.
50 The context pointed to is invalid.
53 The AIO context specified by \fIctx_id\fP is invalid.
57 is not implemented on this architecture.
59 The asynchronous I/O system calls first appeared in Linux 2.5.
62 is Linux-specific and should not be used in programs
63 that are intended to be portable.
65 You probably want to use the
67 wrapper function provided by
68 .\" http://git.fedorahosted.org/git/?p=libaio.git
73 wrapper function uses a different type
75 .\" But glibc is confused, since <libaio.h> uses 'io_context_t' to declare
82 wrapper does not follow the usual C library conventions for indicating errors:
83 on error it returns a negated error number
84 (the negative of one of the values listed in ERRORS).
85 If the system call is invoked via
87 then the return value follows the usual conventions for
88 indicating an error: \-1, with
90 set to a (positive) value that indicates the error.