aboutsummaryrefslogtreecommitdiff
path: root/sys/sys/_sigset.h
diff options
context:
space:
mode:
authorAlan Cox <alc@FreeBSD.org>2000-11-21 19:36:36 +0000
committerAlan Cox <alc@FreeBSD.org>2000-11-21 19:36:36 +0000
commitc6fa9f78d2ffa31f403b2d8830b53cf10d1384c0 (patch)
tree1a113e48114cf11b337f8425ca17e1643636b196 /sys/sys/_sigset.h
parent0fb3a412006cb8af436159d09690f122eb4f9d0d (diff)
downloadsrc-c6fa9f78d2ffa31f403b2d8830b53cf10d1384c0.tar.gz
src-c6fa9f78d2ffa31f403b2d8830b53cf10d1384c0.zip
Provide a new interface for the user of aio_read() and aio_write() to request
a kevent upon completion of the I/O. Specifically, introduce a new type of sigevent notification, SIGEV_EVENT. If sigev_notify is SIGEV_EVENT, then sigev_notify_kqueue names the kqueue that should receive the event and sigev_value contains the "void *" is copied into the kevent's udata field. In contrast to the existing interface, this one: 1) works on the Alpha 2) avoids the extra copyin() call for the kevent because all of the information needed is in the sigevent and 3) could be applied to request a single kevent upon completion of an entire lio_listio(). Reviewed by: jlemon
Notes
Notes: svn path=/head/; revision=69002
Diffstat (limited to 'sys/sys/_sigset.h')
-rw-r--r--sys/sys/_sigset.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/sys/sys/_sigset.h b/sys/sys/_sigset.h
index e3bef902d77a..95891ffd78bc 100644
--- a/sys/sys/_sigset.h
+++ b/sys/sys/_sigset.h
@@ -133,12 +133,18 @@ union sigval {
struct sigevent {
int sigev_notify; /* Notification type */
- int sigev_signo; /* Signal number */
+ union {
+ int __sigev_signo; /* Signal number */
+ int __sigev_notify_kqueue;
+ } __sigev_u;
union sigval sigev_value; /* Signal value */
};
+#define sigev_signo __sigev_u.__sigev_signo
+#define sigev_notify_kqueue __sigev_u.__sigev_notify_kqueue
#define SIGEV_NONE 0 /* No async notification */
#define SIGEV_SIGNAL 1 /* Generate a queued signal */
+#define SIGEV_KEVENT 3 /* Generate a kevent */
typedef struct __siginfo {
int si_signo; /* signal number */