signalfd.h 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
  2. /*
  3. * include/linux/signalfd.h
  4. *
  5. * Copyright (C) 2007 Davide Libenzi <davidel@xmailserver.org>
  6. *
  7. */
  8. #ifndef _UAPI_LINUX_SIGNALFD_H
  9. #define _UAPI_LINUX_SIGNALFD_H
  10. #include <linux/types.h>
  11. /* For O_CLOEXEC and O_NONBLOCK */
  12. #include <linux/fcntl.h>
  13. /* Flags for signalfd4. */
  14. #define SFD_CLOEXEC O_CLOEXEC
  15. #define SFD_NONBLOCK O_NONBLOCK
  16. struct signalfd_siginfo {
  17. __u32 ssi_signo;
  18. __s32 ssi_errno;
  19. __s32 ssi_code;
  20. __u32 ssi_pid;
  21. __u32 ssi_uid;
  22. __s32 ssi_fd;
  23. __u32 ssi_tid;
  24. __u32 ssi_band;
  25. __u32 ssi_overrun;
  26. __u32 ssi_trapno;
  27. __s32 ssi_status;
  28. __s32 ssi_int;
  29. __u64 ssi_ptr;
  30. __u64 ssi_utime;
  31. __u64 ssi_stime;
  32. __u64 ssi_addr;
  33. __u16 ssi_addr_lsb;
  34. __u16 __pad2;
  35. __s32 ssi_syscall;
  36. __u64 ssi_call_addr;
  37. __u32 ssi_arch;
  38. /*
  39. * Pad strcture to 128 bytes. Remember to update the
  40. * pad size when you add new members. We use a fixed
  41. * size structure to avoid compatibility problems with
  42. * future versions, and we leave extra space for additional
  43. * members. We use fixed size members because this strcture
  44. * comes out of a read(2) and we really don't want to have
  45. * a compat on read(2).
  46. */
  47. __u8 __pad[28];
  48. };
  49. #endif /* _UAPI_LINUX_SIGNALFD_H */