remove useless (at best, harmful) feature test checks in aio.h
[musl] / include / aio.h
1 #ifndef _AIO_H
2 #define _AIO_H
3
4 #ifdef __cplusplus
5 extern "C" {
6 #endif
7
8 #include <signal.h>
9 #include <time.h>
10
11 #define __NEED_ssize_t
12 #define __NEED_off_t
13
14 #include <bits/alltypes.h>
15
16 struct aiocb {
17         int aio_fildes, aio_lio_opcode, aio_reqprio;
18         volatile void *aio_buf;
19         size_t aio_nbytes;
20         struct sigevent aio_sigevent;
21         void *__td;
22         int __lock[2];
23         int __err;
24         ssize_t __ret;
25         off_t aio_offset;
26         void *__next, *__prev;
27         char __dummy4[32-2*sizeof(void *)];
28 };
29
30 #define AIO_CANCELED 0
31 #define AIO_NOTCANCELED 1
32 #define AIO_ALLDONE 2
33
34 #define LIO_READ 0
35 #define LIO_WRITE 1
36 #define LIO_NOP 2
37
38 #define LIO_WAIT 0
39 #define LIO_NOWAIT 1
40
41 int aio_read(struct aiocb *);
42 int aio_write(struct aiocb *);
43 int aio_error(const struct aiocb *);
44 ssize_t aio_return(struct aiocb *);
45 int aio_cancel(int, struct aiocb *);
46 int aio_suspend(const struct aiocb *const [], int, const struct timespec *);
47 int aio_fsync(int, struct aiocb *);
48
49 int lio_listio(int, struct aiocb *const [], int, struct sigevent *);
50
51 #ifdef __cplusplus
52 }
53 #endif
54
55 #endif