Remove dependencies on obsolete __ARCH_WANT_SYSCALL_DEPRECATED system calls.
(aarch64 kernels don't have these system calls.)
Change-Id: I6f64075aa412f71520f2df71c3d69b647f91c1ca
diff --git a/libc/include/poll.h b/libc/include/poll.h
index 560be89..0199cab 100644
--- a/libc/include/poll.h
+++ b/libc/include/poll.h
@@ -25,18 +25,21 @@
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*/
+
#ifndef _POLL_H_
#define _POLL_H_
#include <sys/cdefs.h>
#include <linux/poll.h>
+#include <signal.h> /* For sigset_t. */
+#include <time.h> /* For timespec. */
__BEGIN_DECLS
-typedef unsigned int nfds_t;
+typedef unsigned int nfds_t;
-/* POSIX specifies "int" for the timeout, Linux seems to use long... */
-extern int poll(struct pollfd *, nfds_t, long);
+extern int poll(struct pollfd*, nfds_t, int);
+extern int ppoll(struct pollfd*, nfds_t, const struct timespec*, const sigset_t*);
__END_DECLS
diff --git a/libc/include/sys/epoll.h b/libc/include/sys/epoll.h
index 1e207d8..c06a081 100644
--- a/libc/include/sys/epoll.h
+++ b/libc/include/sys/epoll.h
@@ -31,7 +31,8 @@
#include <sys/cdefs.h>
#include <sys/types.h>
-#include <asm/fcntl.h> /* For O_CLOEXEC. */
+#include <fcntl.h> /* For O_CLOEXEC. */
+#include <signal.h> /* For sigset_t. */
__BEGIN_DECLS
@@ -56,24 +57,23 @@
#define EPOLL_CLOEXEC O_CLOEXEC
-typedef union epoll_data
-{
- void *ptr;
- int fd;
- unsigned int u32;
- unsigned long long u64;
+typedef union epoll_data {
+ void* ptr;
+ int fd;
+ uint32_t u32;
+ uint64_t u64;
} epoll_data_t;
-struct epoll_event
-{
- unsigned int events;
- epoll_data_t data;
+struct epoll_event {
+ uint32_t 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);
+int epoll_create(int);
+int epoll_create1(int);
+int epoll_ctl(int, int, int, struct epoll_event*);
+int epoll_wait(int, struct epoll_event*, int, int);
+int epoll_pwait(int, struct epoll_event*, int, int, const sigset_t*);
__END_DECLS