diff options
author | "Steven J. Hill" <sjhill@realitydiluted.com> | 2005-11-29 04:01:23 +0000 |
---|---|---|
committer | "Steven J. Hill" <sjhill@realitydiluted.com> | 2005-11-29 04:01:23 +0000 |
commit | a59b354f62710a795eb1675bab89047ad1618e3b (patch) | |
tree | d212209de762886835ae63c9d1dcb161628de6d8 /librt/kernel-posix-timers.h | |
parent | 2d9da2f6be3e662889ef0e72759fe0f1a1495812 (diff) | |
download | uClibc-alpine-a59b354f62710a795eb1675bab89047ad1618e3b.tar.bz2 uClibc-alpine-a59b354f62710a795eb1675bab89047ad1618e3b.tar.xz |
Merge from trunk.
Diffstat (limited to 'librt/kernel-posix-timers.h')
-rw-r--r-- | librt/kernel-posix-timers.h | 72 |
1 files changed, 21 insertions, 51 deletions
diff --git a/librt/kernel-posix-timers.h b/librt/kernel-posix-timers.h index d8d2ba2c0..bf246c925 100644 --- a/librt/kernel-posix-timers.h +++ b/librt/kernel-posix-timers.h @@ -1,66 +1,36 @@ -/* Copyright (C) 2003 Free Software Foundation, Inc. - This file is part of the GNU C Library. - Contributed by Ulrich Drepper <drepper@redhat.com>, 2003. +/* + * kernel-posix-timers.h - kernel-dependent definitions for POSIX timers. + */ - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public License as - published by the Free Software Foundation; either version 2.1 of the - License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; see the file COPYING.LIB. If not, - write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, - Boston, MA 02111-1307, USA. */ - -#ifdef __UCLIBC_HAS_THREADS__ -#include <pthread.h> -#endif +#include <features.h> #include <setjmp.h> #include <signal.h> #include <sys/types.h> - - -/* Nonzero if the system calls are not available. */ -extern int __no_posix_timers attribute_hidden; - -/* Callback to start helper thread. */ -extern void __start_helper_thread (void) attribute_hidden; - #ifdef __UCLIBC_HAS_THREADS__ -/* Control variable for helper thread creation. */ -extern pthread_once_t __helper_once attribute_hidden; +#include <pthread.h> #endif -/* TID of the helper thread. */ -extern pid_t __helper_tid attribute_hidden; - - -/* Type of timers in the kernel. */ +/* Type of timers in the kernel */ typedef int kernel_timer_t; +/* Internal representation of timer */ +struct timer { + /* Notification mechanism */ + int sigev_notify; -/* Internal representation of timer. */ -struct timer -{ - /* Notification mechanism. */ - int sigev_notify; - - /* Timer ID returned by the kernel. */ - kernel_timer_t ktimerid; + /* Timer ID returned by the kernel */ + kernel_timer_t ktimerid; - /* All new elements must be added after ktimerid. And if the thrfunc - element is not the third element anymore the memory allocation in - timer_create needs to be changed. */ + /* + * All new elements must be added after ktimerid. And if the thrfunc + * element is not the third element anymore the memory allocation in + * timer_create needs to be changed. + */ - /* Parameters for the thread to be started for SIGEV_THREAD. */ - void (*thrfunc) (sigval_t); - sigval_t sival; + /* Parameters for the thread to be started for SIGEV_THREAD */ + void (*thrfunc) (sigval_t); + sigval_t sival; #ifdef __UCLIBC_HAS_THREADS__ - pthread_attr_t attr; + pthread_attr_t attr; #endif }; |