+#include <kern/queue.h>
+
+extern boolean_t mach_timer_coalescing_enabled;
+extern void timer_call_queue_init(mpqueue_head_t *);
+#endif
+
+/*
+ * NOTE: for now, bsd/dev/dtrace/dtrace_glue.c has its own definition
+ * of this data structure, and the two had better match.
+ */
+typedef struct timer_call {
+ struct call_entry call_entry;
+ decl_simple_lock_data( ,lock); /* protects call_entry queue */
+ uint64_t soft_deadline;
+ uint32_t flags;
+ boolean_t async_dequeue; /* this field is protected by
+ call_entry queue's lock */
+ uint64_t ttd; /* Time to deadline at creation */
+} timer_call_data_t, *timer_call_t;
+
+#define EndOfAllTime 0xFFFFFFFFFFFFFFFFULL
+
+typedef void *timer_call_param_t;
+typedef void (*timer_call_func_t)(
+ timer_call_param_t param0,
+ timer_call_param_t param1);
+
+/*
+ * Flags to alter the default timer/timeout coalescing behavior
+ * on a per-timer_call basis.
+ *
+ * The SYS urgency classes indicate that the timer_call is not
+ * directly related to the current thread at the time the timer_call
+ * is entered, so it is ignored in the calculation entirely (only
+ * the subclass specified is used).
+ *
+ * The USER flags indicate that both the current thread scheduling and QoS
+ * attributes, in addition to the per-timer_call urgency specification,
+ * are used to establish coalescing behavior.
+ */
+#define TIMER_CALL_SYS_NORMAL TIMEOUT_URGENCY_SYS_NORMAL
+#define TIMER_CALL_SYS_CRITICAL TIMEOUT_URGENCY_SYS_CRITICAL
+#define TIMER_CALL_SYS_BACKGROUND TIMEOUT_URGENCY_SYS_BACKGROUND