Merged signals-merge branch into trunk with the following changes:
* Reorganized the kernel locking related to threads and teams. * We now discriminate correctly between process and thread signals. Signal handlers have been moved to teams. Fixes #5679. * Implemented real-time signal support, including signal queuing, SA_SIGINFO support, sigqueue(), sigwaitinfo(), sigtimedwait(), waitid(), and the addition of the real-time signal range. Closes #1935 and #2695. * Gave SIGBUS a separate signal number. Fixes #6704. * Implemented <time.h> clock and timer support, and fixed/completed alarm() and [set]itimer(). Closes #5682. * Implemented support for thread cancellation. Closes #5686. * Moved send_signal() from <signal.h> to <OS.h>. Fixes #7554. * Lots over smaller more or less related changes. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42116 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/*
|
||||
/*
|
||||
** Copyright 2003-2004, Axel Dörfler, [email protected]. All rights reserved.
|
||||
** Distributed under the terms of the OpenBeOS License.
|
||||
*/
|
||||
@@ -15,8 +15,21 @@ extern "C" {
|
||||
|
||||
struct kernel_args;
|
||||
|
||||
#define B_TIMER_ACQUIRE_THREAD_LOCK 0x8000
|
||||
#define B_TIMER_FLAGS B_TIMER_ACQUIRE_THREAD_LOCK
|
||||
#define B_TIMER_REAL_TIME_BASE 0x2000
|
||||
// For an absolute timer the given time is interpreted as a real-time, not
|
||||
// as a system time. Note that setting the real-time clock will cause the
|
||||
// timer to be updated -- it will expire according to the new clock.
|
||||
// Relative timers are unaffected by this flag.
|
||||
#define B_TIMER_USE_TIMER_STRUCT_TIMES 0x4000
|
||||
// For add_timer(): Use the timer::schedule_time (absolute time) and
|
||||
// timer::period values instead of the period parameter.
|
||||
#define B_TIMER_ACQUIRE_SCHEDULER_LOCK 0x8000
|
||||
// The timer hook is invoked with the scheduler lock held. When invoking
|
||||
// cancel_timer() with the scheduler lock held, too, this helps to avoid
|
||||
// race conditions.
|
||||
#define B_TIMER_FLAGS \
|
||||
(B_TIMER_USE_TIMER_STRUCT_TIMES | B_TIMER_ACQUIRE_SCHEDULER_LOCK \
|
||||
| B_TIMER_REAL_TIME_BASE)
|
||||
|
||||
/* Timer info structure */
|
||||
struct timer_info {
|
||||
@@ -32,6 +45,8 @@ typedef struct timer_info timer_info;
|
||||
|
||||
/* kernel functions */
|
||||
status_t timer_init(struct kernel_args *);
|
||||
void timer_init_post_rtc(void);
|
||||
void timer_real_time_clock_changed();
|
||||
int32 timer_interrupt(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
Reference in New Issue
Block a user