blob: 7704cb3626c62979e9ff930593b88187b4091a49 [file] [log] [blame]
Elliott Hughes180edef2023-11-02 00:08:05 +00001/*
2 * This file is auto-generated. Modifications will be lost.
3 *
4 * See https://android.googlesource.com/platform/bionic/+/master/libc/kernel/
5 * for more information.
6 */
Ben Cheng655a7c02013-10-16 16:09:24 -07007#ifndef _UAPI_LINUX_EVENTPOLL_H
8#define _UAPI_LINUX_EVENTPOLL_H
Elliott Hughes64f355f2017-08-30 16:10:24 -07009#include <bits/epoll_event.h>
Ben Cheng655a7c02013-10-16 16:09:24 -070010#include <linux/fcntl.h>
11#include <linux/types.h>
Ben Cheng655a7c02013-10-16 16:09:24 -070012#define EPOLL_CLOEXEC O_CLOEXEC
13#define EPOLL_CTL_ADD 1
14#define EPOLL_CTL_DEL 2
15#define EPOLL_CTL_MOD 3
Elliott Hughes0f0c18f2023-03-29 15:53:31 -070016#define EPOLLIN ( __poll_t) 0x00000001
17#define EPOLLPRI ( __poll_t) 0x00000002
18#define EPOLLOUT ( __poll_t) 0x00000004
19#define EPOLLERR ( __poll_t) 0x00000008
20#define EPOLLHUP ( __poll_t) 0x00000010
21#define EPOLLNVAL ( __poll_t) 0x00000020
22#define EPOLLRDNORM ( __poll_t) 0x00000040
23#define EPOLLRDBAND ( __poll_t) 0x00000080
24#define EPOLLWRNORM ( __poll_t) 0x00000100
25#define EPOLLWRBAND ( __poll_t) 0x00000200
26#define EPOLLMSG ( __poll_t) 0x00000400
27#define EPOLLRDHUP ( __poll_t) 0x00002000
28#define EPOLL_URING_WAKE (( __poll_t) (1U << 27))
29#define EPOLLEXCLUSIVE (( __poll_t) (1U << 28))
30#define EPOLLWAKEUP (( __poll_t) (1U << 29))
31#define EPOLLONESHOT (( __poll_t) (1U << 30))
32#define EPOLLET (( __poll_t) (1U << 31))
Christopher Ferris106b3a82016-08-24 12:15:38 -070033#ifdef __x86_64__
Ben Cheng655a7c02013-10-16 16:09:24 -070034#define EPOLL_PACKED __attribute__((packed))
35#else
36#define EPOLL_PACKED
Christopher Ferris106b3a82016-08-24 12:15:38 -070037#endif
Christopher Ferris7f4c8372024-06-03 14:22:19 -070038struct epoll_params {
39 __u32 busy_poll_usecs;
40 __u16 busy_poll_budget;
41 __u8 prefer_busy_poll;
42 __u8 __pad;
43};
44#define EPOLL_IOC_TYPE 0x8A
45#define EPIOCSPARAMS _IOW(EPOLL_IOC_TYPE, 0x01, struct epoll_params)
46#define EPIOCGPARAMS _IOR(EPOLL_IOC_TYPE, 0x02, struct epoll_params)
Nick Kralevicha67e4de2013-01-14 11:28:26 -080047#endif