2 * Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
4 * @APPLE_LICENSE_HEADER_START@
6 * The contents of this file constitute Original Code as defined in and
7 * are subject to the Apple Public Source License Version 1.1 (the
8 * "License"). You may not use this file except in compliance with the
9 * License. Please obtain a copy of the License at
10 * http://www.apple.com/publicsource and read it before using this file.
12 * This Original Code and all software distributed under the License are
13 * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
14 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
15 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
16 * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the
17 * License for the specific language governing rights and limitations
20 * @APPLE_LICENSE_HEADER_END@
23 #include <mach/boolean.h>
24 #include <mach/message.h>
25 #include <mach/kern_return.h>
26 #include <mach/mach_traps.h>
27 #include <mach/mach_types.h>
28 #include <mach/clock_types.h>
30 kern_return_t
semaphore_signal(
31 mach_port_t signal_semaphore
)
33 return semaphore_signal_trap(signal_semaphore
);
36 kern_return_t
semaphore_signal_all(
37 mach_port_t signal_semaphore
)
39 return semaphore_signal_all_trap(signal_semaphore
);
42 kern_return_t
semaphore_signal_thread(
43 mach_port_t signal_semaphore
,
44 mach_port_t thread_act
)
46 return semaphore_signal_thread_trap(signal_semaphore
, thread_act
);
49 kern_return_t
semaphore_wait (
50 mach_port_t wait_semaphore
)
52 return semaphore_wait_trap(wait_semaphore
);
55 kern_return_t
semaphore_timedwait (
56 mach_port_t wait_semaphore
,
57 mach_timespec_t wait_time
)
59 return semaphore_timedwait_trap(wait_semaphore
,
64 kern_return_t
semaphore_wait_signal (
65 mach_port_t wait_semaphore
,
66 mach_port_t signal_semaphore
)
68 return semaphore_wait_signal_trap(wait_semaphore
, signal_semaphore
);
71 kern_return_t
semaphore_timedwait_signal (
72 mach_port_t wait_semaphore
,
73 mach_port_t signal_semaphore
,
74 mach_timespec_t wait_time
)
76 return semaphore_timedwait_signal_trap(wait_semaphore
,