struct mach_call_args args = { 0, 0, 0, 0, 0, 0, 0, 0, 0 };
x86_saved_state32_t *regs;
+#if PROC_REF_DEBUG
+ struct uthread *ut = get_bsdthread_info(current_thread());
+
+ uthread_reset_proc_refcount(ut);
+#endif
+
assert(is_saved_state32(state));
regs = saved_state32(state);
throttle_lowpri_io(1);
+#if PROC_REF_DEBUG
+ if (__improbable(uthread_get_proc_refcount(ut) != 0)) {
+ panic("system call returned with uu_proc_refcount != 0");
+ }
+#endif
+
thread_exception_return();
/* NOTREACHED */
}
struct mach_call_args args = { 0, 0, 0, 0, 0, 0, 0, 0, 0 };
x86_saved_state64_t *regs;
+#if PROC_REF_DEBUG
+ struct uthread *ut = get_bsdthread_info(current_thread());
+
+ uthread_reset_proc_refcount(ut);
+#endif
+
assert(is_saved_state64(state));
regs = saved_state64(state);
throttle_lowpri_io(1);
+#if PROC_REF_DEBUG
+ if (__improbable(uthread_get_proc_refcount(ut) != 0)) {
+ panic("system call returned with uu_proc_refcount != 0");
+ }
+#endif
+
thread_exception_return();
/* NOTREACHED */
}