summaryrefslogtreecommitdiffstats
path: root/lib/librt/sigev_thread.c
diff options
context:
space:
mode:
authorrmh <rmh@FreeBSD.org>2012-03-26 19:12:09 +0000
committerrmh <rmh@FreeBSD.org>2012-03-26 19:12:09 +0000
commit08e0b420dcedc5b64104d9d74e313882312dbe8e (patch)
tree80b88c4d9c41d576905f6192fe0fc653621ad850 /lib/librt/sigev_thread.c
parentd37628cc987706fd89b1b0629b4539e32cd24ee2 (diff)
downloadFreeBSD-src-08e0b420dcedc5b64104d9d74e313882312dbe8e.zip
FreeBSD-src-08e0b420dcedc5b64104d9d74e313882312dbe8e.tar.gz
Register signal 33 explicitly as reserved by real-time library, and
use it by its new name (SIGLIBRT) rather than internal definition in librt (SIGSERVICE). Approved by: davidxu, arch
Diffstat (limited to 'lib/librt/sigev_thread.c')
-rw-r--r--lib/librt/sigev_thread.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/librt/sigev_thread.c b/lib/librt/sigev_thread.c
index 2277330..0246c0c 100644
--- a/lib/librt/sigev_thread.c
+++ b/lib/librt/sigev_thread.c
@@ -224,11 +224,11 @@ __sigev_get_sigevent(struct sigev_node *sn, struct sigevent *newevp,
sigev_id_t id)
{
/*
- * Build a new sigevent, and tell kernel to deliver SIGSERVICE
+ * Build a new sigevent, and tell kernel to deliver SIGLIBRT
* signal to the new thread.
*/
newevp->sigev_notify = SIGEV_THREAD_ID;
- newevp->sigev_signo = SIGSERVICE;
+ newevp->sigev_signo = SIGLIBRT;
newevp->sigev_notify_thread_id = (lwpid_t)sn->sn_tn->tn_lwpid;
newevp->sigev_value.sival_ptr = (void *)id;
}
@@ -279,7 +279,7 @@ __sigev_delete_node(struct sigev_node *sn)
LIST_REMOVE(sn, sn_link);
if (--sn->sn_tn->tn_refcount == 0)
- _pthread_kill(sn->sn_tn->tn_thread, SIGSERVICE);
+ _pthread_kill(sn->sn_tn->tn_thread, SIGLIBRT);
if (sn->sn_flags & SNF_WORKING)
sn->sn_flags |= SNF_REMOVED;
else
@@ -326,7 +326,7 @@ sigev_thread_create(int usedefault)
LIST_INSERT_HEAD(&sigev_threads, tn, tn_link);
__sigev_list_unlock();
- sigfillset(&set); /* SIGSERVICE is masked. */
+ sigfillset(&set); /* SIGLIBRT is masked. */
sigdelset(&set, SIGBUS);
sigdelset(&set, SIGILL);
sigdelset(&set, SIGFPE);
@@ -378,7 +378,7 @@ sigev_service_loop(void *arg)
__sigev_list_unlock();
sigemptyset(&set);
- sigaddset(&set, SIGSERVICE);
+ sigaddset(&set, SIGLIBRT);
for (;;) {
ret = sigwaitinfo(&set, &si);
OpenPOWER on IntegriCloud