#include <mach/std_types.defs>
#include <mach/mach_types.defs>
+#if !KERNEL && !LIBSYSCALL_INTERFACE
+#define PREFIX(NAME) _kernelrpc_ ## NAME
+#else
+#define PREFIX(NAME) NAME
+#endif
+
/*
* Destroy the target thread.
*
* If the thread is currently executing, the state change
* may be ill-defined.
*/
-routine act_set_state(
+routine
+#ifdef KERNEL_SERVER
+act_set_state_from_user(
+#else
+act_set_state(
+#endif
target_act : thread_act_t;
flavor : int;
new_state : thread_state_t);
* If the thread is currently executing, the state change
* may be ill-defined.
*/
-routine thread_set_state(
+routine
+#ifdef KERNEL_SERVER
+thread_set_state_from_user(
+#else
+thread_set_state(
+#endif
target_act : thread_act_t;
flavor : thread_state_flavor_t;
new_state : thread_state_t);
/*
* OBSOLETE interface.
*/
-routine thread_policy(
+routine PREFIX(thread_policy)(
thr_act : thread_act_t;
policy : policy_t;
base : policy_base_t;
* (Approved Mac OS X microkernel interface)
*/
-routine thread_policy_set(
+routine PREFIX(thread_policy_set)(
thread : thread_act_t;
flavor : thread_policy_flavor_t;
policy_info : thread_policy_t);
/*
* OBSOLETE interface.
*/
-routine thread_set_policy(
- thr_act : thread_act_t;
- pset : processor_set_t;
- policy : policy_t;
- base : policy_base_t;
- limit : policy_limit_t);
+routine PREFIX(thread_set_policy)(
+ thr_act : thread_act_t;
+ pset : processor_set_t;
+ policy : policy_t;
+ base : policy_base_t;
+ limit : policy_limit_t);
+
+routine thread_get_mach_voucher(
+ thr_act : thread_act_t;
+ which : mach_voucher_selector_t;
+ out voucher : ipc_voucher_t);
+
+routine thread_set_mach_voucher(
+ thr_act : thread_act_t;
+ voucher : ipc_voucher_t);
+
+routine thread_swap_mach_voucher(
+ thr_act : thread_act_t;
+ new_voucher : ipc_voucher_t;
+ inout old_voucher : ipc_voucher_t);
/* vim: set ft=c : */