summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ipc/ipc_mqueue.h1
-rw-r--r--kern/ipc_kobject.h5
-rw-r--r--kern/syscall_emulation.h6
-rw-r--r--kern/task.c5
4 files changed, 10 insertions, 7 deletions
diff --git a/ipc/ipc_mqueue.h b/ipc/ipc_mqueue.h
index ef0f942..f8a2f1e 100644
--- a/ipc/ipc_mqueue.h
+++ b/ipc/ipc_mqueue.h
@@ -38,6 +38,7 @@
#include <kern/assert.h>
#include <kern/lock.h>
#include <kern/macro_help.h>
+#include <ipc/ipc_kmsg_queue.h>
#include <ipc/ipc_kmsg.h>
#include <ipc/ipc_thread.h>
diff --git a/kern/ipc_kobject.h b/kern/ipc_kobject.h
index cb79574..606a66a 100644
--- a/kern/ipc_kobject.h
+++ b/kern/ipc_kobject.h
@@ -36,13 +36,12 @@
* Declarations for letting a port represent a kernel object.
*/
-#include <ipc/ipc_kmsg.h>
-#include <ipc/ipc_types.h>
-
#ifndef _KERN_IPC_KOBJECT_H_
#define _KERN_IPC_KOBJECT_H_
#include <mach/machine/vm_types.h>
+#include <ipc/ipc_types.h>
+#include <ipc/ipc_kmsg.h>
typedef vm_offset_t ipc_kobject_t;
diff --git a/kern/syscall_emulation.h b/kern/syscall_emulation.h
index 501b0a8..bf20e44 100644
--- a/kern/syscall_emulation.h
+++ b/kern/syscall_emulation.h
@@ -33,6 +33,7 @@
#ifndef __ASSEMBLER__
#include <mach/machine/vm_types.h>
#include <kern/lock.h>
+#include <kern/task.h>
typedef vm_offset_t eml_routine_t;
@@ -56,6 +57,11 @@ typedef vm_offset_t *emulation_vector_t; /* Variable-length array */
#define EML_MOD (err_kern|err_sub(2))
#define EML_BAD_TASK (EML_MOD|0x0001)
#define EML_BAD_CNT (EML_MOD|0x0002)
+
+extern void eml_init(void);
+extern void eml_task_reference(task_t task, task_t parent);
+extern void eml_task_deallocate(task_t task);
+
#endif /* __ASSEMBLER__ */
#endif /* _KERN_SYSCALL_EMULATION_H_ */
diff --git a/kern/task.c b/kern/task.c
index f62e47b..933a90e 100644
--- a/kern/task.c
+++ b/kern/task.c
@@ -47,16 +47,13 @@
#include <kern/processor.h>
#include <kern/sched_prim.h> /* for thread_wakeup */
#include <kern/ipc_tt.h>
+#include <kern/syscall_emulation.h>
#include <vm/vm_kern.h> /* for kernel_map, ipc_kernel_map */
#include <machine/machspl.h> /* for splsched */
task_t kernel_task = TASK_NULL;
struct kmem_cache task_cache;
-extern void eml_init(void);
-extern void eml_task_reference(task_t, task_t);
-extern void eml_task_deallocate(task_t);
-
void task_init(void)
{
kmem_cache_init(&task_cache, "task", sizeof(struct task), 0,