Remove dependencies on obsolete __ARCH_WANT_SYSCALL_NO_FLAGS syscalls.
(aarch64 kernels only have the newer system calls.)
Also expose the new functionality that's exposed by glibc in our header files.
Change-Id: I45d2d168a03f88723d1f7fbf634701006a4843c5
diff --git a/libc/include/sys/epoll.h b/libc/include/sys/epoll.h
index 38739aa..625f4c2 100644
--- a/libc/include/sys/epoll.h
+++ b/libc/include/sys/epoll.h
@@ -29,6 +29,7 @@
#define _SYS_EPOLL_H_
#include <sys/cdefs.h>
+#include <asm/fcntl.h> /* For O_CLOEXEC. */
__BEGIN_DECLS
@@ -51,7 +52,9 @@
#define EPOLL_CTL_DEL 2
#define EPOLL_CTL_MOD 3
-typedef union epoll_data
+#define EPOLL_CLOEXEC O_CLOEXEC
+
+typedef union epoll_data
{
void *ptr;
int fd;
@@ -59,17 +62,17 @@
unsigned long long u64;
} epoll_data_t;
-struct epoll_event
+struct epoll_event
{
unsigned int events;
epoll_data_t data;
};
int epoll_create(int size);
+int epoll_create1(int flags);
int epoll_ctl(int epfd, int op, int fd, struct epoll_event *event);
int epoll_wait(int epfd, struct epoll_event *events, int max, int timeout);
__END_DECLS
#endif /* _SYS_EPOLL_H_ */
-