Initial commit
[lnanohtmltiledmap.git] / ulinux / epoll.h
blobedacba10722cce22b84fdd80db4756d85034aa39
1 #ifndef ULINUX_EPOLL_H
2 #define ULINUX_EPOLL_H
3 /*
4 * this code is protected by the GNU affero GPLv3
5 * author:Sylvain BERTRAND
6 */
7 #ifndef ULINUX_O_CLOEXEC
8 #error "missing definition of ULINUX_O_CLOEXEC"
9 #endif
10 #define ULINUX_EPOLL_CLOEXEC ULINUX_O_CLOEXEC
12 #define ULINUX_EPOLL_CTL_ADD 1
13 #define ULINUX_EPOLL_CTL_DEL 2
14 #define ULINUX_EPOLL_CTL_MOD 3
16 #define ULINUX_EPOLLIN 0x0001
17 #define ULINUX_EPOLLPRI 0x0002
18 #define ULINUX_EPOLLOUT 0x0004
19 #define ULINUX_EPOLLERR 0x0008
20 #define ULINUX_EPOLLHUP 0x0010
21 #define ULINUX_EPOLLNVAL 0x0020
22 #define ULINUX_EPOLLRDHUP 0x2000
23 #define ULINUX_EPOLLONESHOT (1<<30)
24 #define ULINUX_EPOLLET (1<<31)
26 union ulinux_epoll_data{
27 void *ptr;
28 ulinux_si fd;
29 ulinux_u32 _32;
30 ulinux_u64 _64;
33 #include <ulinux/arch/epoll.h>
35 struct ulinux_epoll_event{
36 ulinux_u32 events;
37 union ulinux_epoll_data data;
38 } EPOLL_PACKED; /* Only x86_64 */
39 #endif