poll.h 764 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. #ifndef __ASM_GENERIC_POLL_H
  2. #define __ASM_GENERIC_POLL_H
  3. /* These are specified by iBCS2 */
  4. #define POLLIN 0x0001
  5. #define POLLPRI 0x0002
  6. #define POLLOUT 0x0004
  7. #define POLLERR 0x0008
  8. #define POLLHUP 0x0010
  9. #define POLLNVAL 0x0020
  10. /* The rest seem to be more-or-less nonstandard. Check them! */
  11. #define POLLRDNORM 0x0040
  12. #define POLLRDBAND 0x0080
  13. #ifndef POLLWRNORM
  14. #define POLLWRNORM 0x0100
  15. #endif
  16. #ifndef POLLWRBAND
  17. #define POLLWRBAND 0x0200
  18. #endif
  19. #ifndef POLLMSG
  20. #define POLLMSG 0x0400
  21. #endif
  22. #ifndef POLLREMOVE
  23. #define POLLREMOVE 0x1000
  24. #endif
  25. #ifndef POLLRDHUP
  26. #define POLLRDHUP 0x2000
  27. #endif
  28. #define POLLFREE 0x4000 /* currently only for epoll */
  29. struct pollfd {
  30. int fd;
  31. short events;
  32. short revents;
  33. };
  34. #endif /* __ASM_GENERIC_POLL_H */