summaryrefslogtreecommitdiff
path: root/ipc
diff options
context:
space:
mode:
authorThomas Schwinge <tschwinge@gnu.org>2007-04-30 20:30:11 +0000
committerThomas Schwinge <tschwinge@gnu.org>2009-06-18 00:27:09 +0200
commitbc85b8639e6a4f3133d8bf10161a5947dfb5b29d (patch)
tree5f981ababb0bb14005efb9f1eba00cf9dad741ed /ipc
parent7f320586e5b3c2017b9ddd70bf97ac64f51f1be4 (diff)
2007-04-30 Thomas Schwinge <tschwinge@gnu.org>
We're not in the eighties anymore. List arguments in function prototypes and definitions for a lot of symbols. Also drop some unused prototypes. I refrain from listing every changed symbol. * chips/busses.h: Do as described. * ddb/db_break.c: Likewise. * ddb/db_break.h: Likewise. * ddb/db_command.c: Likewise. * ddb/db_command.h: Likewise. * ddb/db_lex.c: Likewise. * ddb/db_lex.h: Likewise. * ddb/db_output.c: Likewise. * ddb/db_output.h: Likewise. * ddb/db_sym.h: Likewise. * ddb/db_task_thread.c: Likewise. * ddb/db_task_thread.h: Likewise. * ddb/db_variables.h: Likewise. * ddb/db_watch.c: Likewise. * ddb/db_watch.h: Likewise. * device/buf.h: Likewise. * device/conf.h: Likewise. * device/dev_hdr.h: Likewise. * device/ds_routines.h: Likewise. * device/if_ether.h: Likewise. * device/io_req.h: Likewise. * device/net_io.h: Likewise. * i386/i386/io_port.h: Likewise. * i386/i386/lock.h: Likewise. * i386/i386/mp_desc.c: Likewise. * i386/i386/mp_desc.h: Likewise. * i386/i386/proc_reg.h: Likewise. * i386/i386/user_ldt.h: Likewise. * i386/i386at/kd_queue.h: Likewise. * i386/i386at/kdsoft.h: Likewise. * i386/intel/pmap.c: Likewise. * i386/intel/pmap.h: Likewise. * include/mach/mach_traps.h: Likewise. * ipc/ipc_entry.h: Likewise. * ipc/ipc_hash.h: Likewise. * ipc/ipc_kmsg.h: Likewise. * ipc/ipc_marequest.c: Likewise. * ipc/ipc_marequest.h: Likewise. * ipc/ipc_mqueue.h: Likewise. * ipc/ipc_notify.h: Likewise. * ipc/ipc_object.h: Likewise. * ipc/ipc_port.h: Likewise. * ipc/ipc_pset.h: Likewise. * ipc/ipc_right.h: Likewise. * ipc/ipc_space.h: Likewise. * ipc/ipc_table.h: Likewise. * ipc/mach_msg.c: Likewise. * ipc/mach_msg.h: Likewise. * kern/ast.c: Likewise. * kern/ast.h: Likewise. * kern/debug.c: Likewise. * kern/debug.h: Likewise. * kern/ipc_tt.c: Likewise. * kern/ipc_tt.h: Likewise. * kern/mach_factor.c: Likewise. * kern/mach_factor.h: Likewise. * kern/printf.c: Likewise. * kern/printf.h: Likewise. * kern/queue.h: Likewise. * kern/sched.h: Likewise. * kern/syscall_subr.c: Likewise. * kern/syscall_subr.h: Likewise. * kern/task.h: Likewise. * kern/thread_swap.c: Likewise. * kern/thread_swap.h: Likewise. * kern/timer.h: Likewise. * kern/xpr.c: Likewise. * kern/xpr.h: Likewise. * kern/zalloc.c: Likewise. * kern/zalloc.h: Likewise. * ipc/ipc_port.h: Don't include <ipc/ipc_space.h>. * device/net_io.h: Include <device/if_hdr.h> and <device/io_req.h>. * ipc/ipc_entry.h: Include <mach/mach_types.h> and <ipc/ipc_types.h>. * ipc/ipc_kmsg.h: Include <ipc/ipc_object.h>, <ipc/ipc_types.h> and <vm/vm_map.h>. * ipc/ipc_marequest.h: Include <mach_debug/hash_info.h> and <ipc/ipc_types.h>. * ipc/ipc_object.h: Include <ipc/ipc_types.h>. * ipc/ipc_right.h: Include <ipc/ipc_entry.h>. * ipc/ipc_space.h: Include <mach/mach_types.h> and <ipc/ipc_types.h>. * kern/ipc_tt.h: Include <mach/mach_types.h>. * kern/sched.h: Include <kern/kern_types.h>. * ipc/ipc_hash.c (ipc_hash_index_t): Move type definition... * ipc/ipc_hash.h: ... into here.
Diffstat (limited to 'ipc')
-rw-r--r--ipc/ipc_entry.h18
-rw-r--r--ipc/ipc_hash.c2
-rw-r--r--ipc/ipc_hash.h44
-rw-r--r--ipc/ipc_kmsg.h38
-rw-r--r--ipc/ipc_marequest.c2
-rw-r--r--ipc/ipc_marequest.h18
-rw-r--r--ipc/ipc_mqueue.h16
-rw-r--r--ipc/ipc_notify.h14
-rw-r--r--ipc/ipc_object.h51
-rw-r--r--ipc/ipc_port.h49
-rw-r--r--ipc/ipc_pset.h14
-rw-r--r--ipc/ipc_right.h57
-rw-r--r--ipc/ipc_space.h4
-rw-r--r--ipc/ipc_table.h2
-rw-r--r--ipc/mach_msg.c4
-rw-r--r--ipc/mach_msg.h16
16 files changed, 177 insertions, 172 deletions
diff --git a/ipc/ipc_entry.h b/ipc/ipc_entry.h
index 6e316bd..a577cf0 100644
--- a/ipc/ipc_entry.h
+++ b/ipc/ipc_entry.h
@@ -38,11 +38,13 @@
#ifndef _IPC_IPC_ENTRY_H_
#define _IPC_IPC_ENTRY_H_
+#include <mach/mach_types.h>
#include <mach/port.h>
#include <mach/kern_return.h>
#include <kern/zalloc.h>
#include <ipc/port.h>
#include <ipc/ipc_table.h>
+#include <ipc/ipc_types.h>
/*
* Spaces hold capabilities for ipc_object_t's (ports and port sets).
@@ -134,25 +136,21 @@ extern zone_t ipc_tree_entry_zone;
extern ipc_entry_t
-ipc_entry_lookup(/* ipc_space_t space, mach_port_t name */);
+ipc_entry_lookup(ipc_space_t space, mach_port_t name);
extern kern_return_t
-ipc_entry_get(/* ipc_space_t space,
- mach_port_t *namep, ipc_entry_t *entryp */);
+ipc_entry_get(ipc_space_t space, mach_port_t *namep, ipc_entry_t *entryp);
extern kern_return_t
-ipc_entry_alloc(/* ipc_space_t space,
- mach_port_t *namep, ipc_entry_t *entryp */);
+ipc_entry_alloc(ipc_space_t space, mach_port_t *namep, ipc_entry_t *entryp);
extern kern_return_t
-ipc_entry_alloc_name(/* ipc_space_t space, mach_port_t name,
- ipc_entry_t *entryp */);
+ipc_entry_alloc_name(ipc_space_t space, mach_port_t name, ipc_entry_t *entryp);
extern void
-ipc_entry_dealloc(/* ipc_space_t space, mach_port_t name,
- ipc_entry_t entry */);
+ipc_entry_dealloc(ipc_space_t space, mach_port_t name, ipc_entry_t entry);
extern kern_return_t
-ipc_entry_grow_table(/* ipc_space_t space */);
+ipc_entry_grow_table(ipc_space_t space);
#endif /* _IPC_IPC_ENTRY_H_ */
diff --git a/ipc/ipc_hash.c b/ipc/ipc_hash.c
index ce720c7..c241289 100644
--- a/ipc/ipc_hash.c
+++ b/ipc/ipc_hash.c
@@ -136,8 +136,6 @@ ipc_hash_delete(
* Within each bucket, move-to-front is used.
*/
-typedef natural_t ipc_hash_index_t;
-
ipc_hash_index_t ipc_hash_global_size;
ipc_hash_index_t ipc_hash_global_mask;
diff --git a/ipc/ipc_hash.h b/ipc/ipc_hash.h
index b5b1ba6..58c56ca 100644
--- a/ipc/ipc_hash.h
+++ b/ipc/ipc_hash.h
@@ -37,27 +37,29 @@
#include <mach/boolean.h>
#include <mach/kern_return.h>
+typedef natural_t ipc_hash_index_t;
+
extern void
-ipc_hash_init();
+ipc_hash_init(void);
#if MACH_IPC_DEBUG
-extern unsigned int
-ipc_hash_info(/* hash_info_bucket_t *, unsigned int */);
+extern ipc_hash_index_t
+ipc_hash_info(hash_info_bucket_t *, mach_msg_type_number_t);
#endif /* MACH_IPC_DEBUG */
extern boolean_t
-ipc_hash_lookup(/* ipc_space_t space, ipc_object_t obj,
- mach_port_t *namep, ipc_entry_t *entryp */);
+ipc_hash_lookup(ipc_space_t space, ipc_object_t obj,
+ mach_port_t *namep, ipc_entry_t *entryp);
extern void
-ipc_hash_insert(/* ipc_space_t space, ipc_object_t obj,
- mach_port_t name, ipc_entry_t entry */);
+ipc_hash_insert(ipc_space_t space, ipc_object_t obj,
+ mach_port_t name, ipc_entry_t entry);
extern void
-ipc_hash_delete(/* ipc_space_t space, ipc_object_t obj,
- mach_port_t name, ipc_entry_t entry */);
+ipc_hash_delete(ipc_space_t space, ipc_object_t obj,
+ mach_port_t name, ipc_entry_t entry);
/*
* For use by functions that know what they're doing:
@@ -66,27 +68,27 @@ ipc_hash_delete(/* ipc_space_t space, ipc_object_t obj,
*/
extern boolean_t
-ipc_hash_global_lookup(/* ipc_space_t space, ipc_object_t obj,
- mach_port_t *namep, ipc_tree_entry_t *entryp */);
+ipc_hash_global_lookup(ipc_space_t space, ipc_object_t obj,
+ mach_port_t *namep, ipc_tree_entry_t *entryp);
extern void
-ipc_hash_global_insert(/* ipc_space_t space, ipc_object_t obj,
- mach_port_t name, ipc_tree_entry_t entry */);
+ipc_hash_global_insert(ipc_space_t space, ipc_object_t obj,
+ mach_port_t name, ipc_tree_entry_t entry);
extern void
-ipc_hash_global_delete(/* ipc_space_t space, ipc_object_t obj,
- mach_port_t name, ipc_tree_entry_t entry */);
+ipc_hash_global_delete(ipc_space_t space, ipc_object_t obj,
+ mach_port_t name, ipc_tree_entry_t entry);
extern boolean_t
-ipc_hash_local_lookup(/* ipc_space_t space, ipc_object_t obj,
- mach_port_t *namep, ipc_entry_t *entryp */);
+ipc_hash_local_lookup(ipc_space_t space, ipc_object_t obj,
+ mach_port_t *namep, ipc_entry_t *entryp);
extern void
-ipc_hash_local_insert(/* ipc_space_t space, ipc_object_t obj,
- mach_port_index_t index, ipc_entry_t entry */);
+ipc_hash_local_insert(ipc_space_t space, ipc_object_t obj,
+ mach_port_index_t index, ipc_entry_t entry);
extern void
-ipc_hash_local_delete(/* ipc_space_t space, ipc_object_t obj,
- mach_port_index_t index, ipc_entry_t entry */);
+ipc_hash_local_delete(ipc_space_t space, ipc_object_t obj,
+ mach_port_index_t index, ipc_entry_t entry);
#endif /* _IPC_IPC_HASH_H_ */
diff --git a/ipc/ipc_kmsg.h b/ipc/ipc_kmsg.h
index 7617692..8867310 100644
--- a/ipc/ipc_kmsg.h
+++ b/ipc/ipc_kmsg.h
@@ -41,6 +41,9 @@
#include <kern/macro_help.h>
#include <kern/kalloc.h>
#include <ipc/ipc_marequest.h>
+#include <ipc/ipc_object.h>
+#include <ipc/ipc_types.h>
+#include <vm/vm_map.h>
/*
* This structure is only the header for a kmsg buffer;
@@ -217,53 +220,52 @@ MACRO_BEGIN \
MACRO_END
extern void
-ipc_kmsg_destroy(/* ipc_kmsg_t */);
+ipc_kmsg_destroy(ipc_kmsg_t);
extern void
-ipc_kmsg_clean(/* ipc_kmsg_t */);
+ipc_kmsg_clean(ipc_kmsg_t);
extern void
-ipc_kmsg_free(/* ipc_kmsg_t */);
+ipc_kmsg_free(ipc_kmsg_t);
extern mach_msg_return_t
-ipc_kmsg_get(/* mach_msg_header_t *, mach_msg_size_t, ipc_kmsg_t * */);
+ipc_kmsg_get(mach_msg_header_t *, mach_msg_size_t, ipc_kmsg_t *);
extern mach_msg_return_t
-ipc_kmsg_get_from_kernel(/* mach_msg_header_t *, mach_msg_size_t,
- ipc_kmsg_t * */);
+ipc_kmsg_get_from_kernel(mach_msg_header_t *, mach_msg_size_t, ipc_kmsg_t *);
extern mach_msg_return_t
-ipc_kmsg_put(/* mach_msg_header_t *, ipc_kmsg_t, mach_msg_size_t */);
+ipc_kmsg_put(mach_msg_header_t *, ipc_kmsg_t, mach_msg_size_t);
extern void
-ipc_kmsg_put_to_kernel(/* mach_msg_header_t *, ipc_kmsg_t, mach_msg_size_t */);
+ipc_kmsg_put_to_kernel(mach_msg_header_t *, ipc_kmsg_t, mach_msg_size_t);
extern mach_msg_return_t
-ipc_kmsg_copyin_header(/* mach_msg_header_t *, ipc_space_t, mach_port_t */);
+ipc_kmsg_copyin_header(mach_msg_header_t *, ipc_space_t, mach_port_t);
extern mach_msg_return_t
-ipc_kmsg_copyin(/* ipc_kmsg_t, ipc_space_t, vm_map_t, mach_port_t */);
+ipc_kmsg_copyin(ipc_kmsg_t, ipc_space_t, vm_map_t, mach_port_t);
extern void
-ipc_kmsg_copyin_from_kernel(/* ipc_kmsg_t */);
+ipc_kmsg_copyin_from_kernel(ipc_kmsg_t);
extern mach_msg_return_t
-ipc_kmsg_copyout_header(/* mach_msg_header_t *, ipc_space_t, mach_port_t */);
+ipc_kmsg_copyout_header(mach_msg_header_t *, ipc_space_t, mach_port_t);
extern mach_msg_return_t
-ipc_kmsg_copyout_object(/* ipc_space_t, ipc_object_t,
- mach_msg_type_name_t, mach_port_t * */);
+ipc_kmsg_copyout_object(ipc_space_t, ipc_object_t,
+ mach_msg_type_name_t, mach_port_t *);
extern mach_msg_return_t
-ipc_kmsg_copyout_body(/* vm_offset_t, vm_offset_t, ipc_space_t, vm_map_t */);
+ipc_kmsg_copyout_body(vm_offset_t, vm_offset_t, ipc_space_t, vm_map_t);
extern mach_msg_return_t
-ipc_kmsg_copyout(/* ipc_kmsg_t, ipc_space_t, vm_map_t, mach_port_t */);
+ipc_kmsg_copyout(ipc_kmsg_t, ipc_space_t, vm_map_t, mach_port_t);
extern mach_msg_return_t
-ipc_kmsg_copyout_pseudo(/* ipc_kmsg_t, ipc_space_t, vm_map_t */);
+ipc_kmsg_copyout_pseudo(ipc_kmsg_t, ipc_space_t, vm_map_t);
extern void
-ipc_kmsg_copyout_dest(/* ipc_kmsg_t, ipc_space_t */);
+ipc_kmsg_copyout_dest(ipc_kmsg_t, ipc_space_t);
#endif /* _IPC_IPC_KMSG_H_ */
diff --git a/ipc/ipc_marequest.c b/ipc/ipc_marequest.c
index 16c6a5f..540382a 100644
--- a/ipc/ipc_marequest.c
+++ b/ipc/ipc_marequest.c
@@ -96,7 +96,7 @@ ipc_marequest_bucket_t ipc_marequest_table;
*/
void
-ipc_marequest_init()
+ipc_marequest_init(void)
{
ipc_marequest_index_t i;
diff --git a/ipc/ipc_marequest.h b/ipc/ipc_marequest.h
index 6f4e6c8..eb3746d 100644
--- a/ipc/ipc_marequest.h
+++ b/ipc/ipc_marequest.h
@@ -36,6 +36,8 @@
#include <mach/kern_return.h>
#include <mach/port.h>
+#include <mach_debug/hash_info.h>
+#include <ipc/ipc_types.h>
/*
* A msg-accepted request is made when MACH_SEND_NOTIFY is used
@@ -70,27 +72,27 @@ typedef struct ipc_marequest {
extern void
-ipc_marequest_init();
+ipc_marequest_init(void);
#if MACH_IPC_DEBUG
extern unsigned int
-ipc_marequest_info(/* unsigned int *, hash_info_bucket_t *, unsigned int */);
+ipc_marequest_info(unsigned int *, hash_info_bucket_t *, unsigned int);
#endif /* MACH_IPC_DEBUG */
extern mach_msg_return_t
-ipc_marequest_create(/* ipc_space_t space, mach_port_t name,
- ipc_port_t soright, ipc_marequest_t *marequestp */);
+ipc_marequest_create(ipc_space_t space, ipc_port_t port,
+ mach_port_t notify, ipc_marequest_t *marequestp);
extern void
-ipc_marequest_cancel(/* ipc_space_t space, mach_port_t name */);
+ipc_marequest_cancel(ipc_space_t space, mach_port_t name);
extern void
-ipc_marequest_rename(/* ipc_space_t space,
- mach_port_t old, mach_port_t new */);
+ipc_marequest_rename(ipc_space_t space,
+ mach_port_t old, mach_port_t new);
extern void
-ipc_marequest_destroy(/* ipc_marequest_t marequest */);
+ipc_marequest_destroy(ipc_marequest_t marequest);
#endif /* _IPC_IPC_MAREQUEST_H_ */
diff --git a/ipc/ipc_mqueue.h b/ipc/ipc_mqueue.h
index 5c284a3..6421aef 100644
--- a/ipc/ipc_mqueue.h
+++ b/ipc/ipc_mqueue.h
@@ -55,24 +55,24 @@ typedef struct ipc_mqueue {
#define imq_unlock(mq) simple_unlock(&(mq)->imq_lock_data)
extern void
-ipc_mqueue_init(/* ipc_mqueue_t */);
+ipc_mqueue_init(ipc_mqueue_t);
extern void
-ipc_mqueue_move(/* ipc_mqueue_t, ipc_mqueue_t, ipc_port_t */);
+ipc_mqueue_move(ipc_mqueue_t, ipc_mqueue_t, ipc_port_t);
extern void
-ipc_mqueue_changed(/* ipc_mqueue_t, mach_msg_return_t */);
+ipc_mqueue_changed(ipc_mqueue_t, mach_msg_return_t);
extern mach_msg_return_t
-ipc_mqueue_send(/* ipc_kmsg_t, mach_msg_option_t, mach_msg_timeout_t */);
+ipc_mqueue_send(ipc_kmsg_t, mach_msg_option_t, mach_msg_timeout_t);
#define IMQ_NULL_CONTINUE ((void (*)()) 0)
extern mach_msg_return_t
-ipc_mqueue_receive(/* ipc_mqueue_t, mach_msg_option_t,
- mach_msg_size_t, mach_msg_timeout_t,
- boolean_t, void (*)(),
- ipc_kmsg_t *, mach_port_seqno_t * */);
+ipc_mqueue_receive(ipc_mqueue_t, mach_msg_option_t,
+ mach_msg_size_t, mach_msg_timeout_t,
+ boolean_t, void (*)(),
+ ipc_kmsg_t *, mach_port_seqno_t *);
/*
* extern void
diff --git a/ipc/ipc_notify.h b/ipc/ipc_notify.h
index 60872a9..789bd23 100644
--- a/ipc/ipc_notify.h
+++ b/ipc/ipc_notify.h
@@ -35,24 +35,24 @@
#define _IPC_IPC_NOTIFY_H_
extern void
-ipc_notify_init();
+ipc_notify_init(void);
extern void
-ipc_notify_port_deleted(/* ipc_port_t, mach_port_t */);
+ipc_notify_port_deleted(ipc_port_t, mach_port_t);
extern void
-ipc_notify_msg_accepted(/* ipc_port_t, mach_port_t */);
+ipc_notify_msg_accepted(ipc_port_t, mach_port_t);
extern void
-ipc_notify_port_destroyed(/* ipc_port_t, ipc_port_t */);
+ipc_notify_port_destroyed(ipc_port_t, ipc_port_t);
extern void
-ipc_notify_no_senders(/* ipc_port_t, mach_port_mscount_t */);
+ipc_notify_no_senders(ipc_port_t, mach_port_mscount_t);
extern void
-ipc_notify_send_once(/* ipc_port_t */);
+ipc_notify_send_once(ipc_port_t);
extern void
-ipc_notify_dead_name(/* ipc_port_t, mach_port_t */);
+ipc_notify_dead_name(ipc_port_t, mach_port_t);
#endif /* _IPC_IPC_NOTIFY_H_ */
diff --git a/ipc/ipc_object.h b/ipc/ipc_object.h
index 7c6eb4e..2bbf8bd 100644
--- a/ipc/ipc_object.h
+++ b/ipc/ipc_object.h
@@ -36,6 +36,7 @@
#include <mach/kern_return.h>
#include <mach/message.h>
+#include <ipc/ipc_types.h>
#include <kern/lock.h>
#include <kern/macro_help.h>
#include <kern/zalloc.h>
@@ -107,60 +108,60 @@ MACRO_BEGIN \
MACRO_END
extern void
-ipc_object_reference(/* ipc_object_t */);
+ipc_object_reference(ipc_object_t);
extern void
-ipc_object_release(/* ipc_object_t */);
+ipc_object_release(ipc_object_t);
extern kern_return_t
-ipc_object_translate(/* ipc_space_t, mach_port_t,
- mach_port_right_t, ipc_object_t * */);
+ipc_object_translate(ipc_space_t, mach_port_t,
+ mach_port_right_t, ipc_object_t *);
extern kern_return_t
-ipc_object_alloc_dead(/* ipc_space_t, mach_port_t * */);
+ipc_object_alloc_dead(ipc_space_t, mach_port_t *);
extern kern_return_t
-ipc_object_alloc_dead_name(/* ipc_space_t, mach_port_t */);
+ipc_object_alloc_dead_name(ipc_space_t, mach_port_t);
extern kern_return_t
-ipc_object_alloc(/* ipc_space_t, ipc_object_type_t,
- mach_port_type_t, mach_port_urefs_t,
- mach_port_t *, ipc_object_t * */);
+ipc_object_alloc(ipc_space_t, ipc_object_type_t,
+ mach_port_type_t, mach_port_urefs_t,
+ mach_port_t *, ipc_object_t *);
extern kern_return_t
-ipc_object_alloc_name(/* ipc_space_t, ipc_object_type_t,
- mach_port_type_t, mach_port_urefs_t,
- mach_port_t, ipc_object_t * */);
+ipc_object_alloc_name(ipc_space_t, ipc_object_type_t,
+ mach_port_type_t, mach_port_urefs_t,
+ mach_port_t, ipc_object_t *);
extern mach_msg_type_name_t
-ipc_object_copyin_type(/* mach_msg_type_name_t */);
+ipc_object_copyin_type(mach_msg_type_name_t);
extern kern_return_t
-ipc_object_copyin(/* ipc_space_t, mach_port_t,
- mach_msg_type_name_t, ipc_object_t * */);
+ipc_object_copyin(ipc_space_t, mach_port_t,
+ mach_msg_type_name_t, ipc_object_t *);
extern void
-ipc_object_copyin_from_kernel(/* ipc_object_t, mach_msg_type_name_t */);
+ipc_object_copyin_from_kernel(ipc_object_t, mach_msg_type_name_t);
extern void
-ipc_object_destroy(/* ipc_object_t, mach_msg_type_name_t */);
+ipc_object_destroy(ipc_object_t, mach_msg_type_name_t);
extern kern_return_t
-ipc_object_copyout(/* ipc_space_t, ipc_object_t,
- mach_msg_type_name_t, boolean_t, mach_port_t * */);
+ipc_object_copyout(ipc_space_t, ipc_object_t,
+ mach_msg_type_name_t, boolean_t, mach_port_t *);
extern kern_return_t
-ipc_object_copyout_name(/* ipc_space_t, ipc_object_t,
- mach_msg_type_name_t, boolean_t, mach_port_t */);
+ipc_object_copyout_name(ipc_space_t, ipc_object_t,
+ mach_msg_type_name_t, boolean_t, mach_port_t);
extern void
-ipc_object_copyout_dest(/* ipc_space_t, ipc_object_t,
- mach_msg_type_name_t, mach_port_t * */);
+ipc_object_copyout_dest(ipc_space_t, ipc_object_t,
+ mach_msg_type_name_t, mach_port_t *);
extern kern_return_t
-ipc_object_rename(/* ipc_space_t, mach_port_t, mach_port_t */);
+ipc_object_rename(ipc_space_t, mach_port_t, mach_port_t);
extern void
-ipc_object_print(/* ipc_object_t */);
+ipc_object_print(ipc_object_t);
#endif /* _IPC_IPC_OBJECT_H_ */
diff --git a/ipc/ipc_port.h b/ipc/ipc_port.h
index 4427861..70ec494 100644
--- a/ipc/ipc_port.h
+++ b/ipc/ipc_port.h
@@ -46,7 +46,6 @@
#include <kern/macro_help.h>
#include <kern/ipc_kobject.h>
#include <ipc/ipc_mqueue.h>
-#include <ipc/ipc_space.h>
#include <ipc/ipc_table.h>
#include <ipc/ipc_thread.h>
#include "ipc_target.h"
@@ -185,7 +184,7 @@ extern ipc_port_timestamp_t ipc_port_timestamp_data;
simple_unlock(&ipc_port_timestamp_lock_data)
extern ipc_port_timestamp_t
-ipc_port_timestamp();
+ipc_port_timestamp(void);
/*
* Compares two timestamps, and returns TRUE if one
@@ -207,14 +206,14 @@ ipc_port_timestamp();
(ipc_object_t *) (portp))
extern kern_return_t
-ipc_port_dnrequest(/* ipc_port_t, mach_port_t, ipc_port_t,
- ipc_port_request_index_t * */);
+ipc_port_dnrequest(ipc_port_t, mach_port_t, ipc_port_t,
+ ipc_port_request_index_t *);
extern kern_return_t
-ipc_port_dngrow(/* ipc_port_t */);
+ipc_port_dngrow(ipc_port_t);
extern ipc_port_t
-ipc_port_dncancel(/* ipc_port_t, mach_port_t, ipc_port_request_index_t */);
+ipc_port_dncancel(ipc_port_t, mach_port_t, ipc_port_request_index_t);
#define ipc_port_dnrename(port, index, oname, nname) \
MACRO_BEGIN \
@@ -257,58 +256,58 @@ MACRO_BEGIN \
MACRO_END
extern struct ipc_mqueue *
-ipc_port_lock_mqueue(/* ipc_port_t */);
+ipc_port_lock_mqueue(ipc_port_t);
extern void
-ipc_port_set_seqno(/* ipc_port_t, mach_port_seqno_t */);
+ipc_port_set_seqno(ipc_port_t, mach_port_seqno_t);
extern void
-ipc_port_clear_receiver(/* ipc_port_t */);
+ipc_port_clear_receiver(ipc_port_t);
extern void
-ipc_port_init(/* ipc_port_t, ipc_space_t, mach_port_t */);
+ipc_port_init(ipc_port_t, ipc_space_t, mach_port_t);
extern kern_return_t
-ipc_port_alloc(/* ipc_space_t, mach_port_t *, ipc_port_t * */);
+ipc_port_alloc(ipc_space_t, mach_port_t *, ipc_port_t *);
extern kern_return_t
-ipc_port_alloc_name(/* ipc_space_t, mach_port_t, ipc_port_t * */);
+ipc_port_alloc_name(ipc_space_t, mach_port_t, ipc_port_t *);
extern void
-ipc_port_destroy(/* ipc_port_t */);
+ipc_port_destroy(ipc_port_t);
extern boolean_t
-ipc_port_check_circularity(/* ipc_port_t, ipc_port_t */);
+ipc_port_check_circularity(ipc_port_t, ipc_port_t);
extern ipc_port_t
-ipc_port_lookup_notify(/* ipc_space_t, mach_port_t */);
+ipc_port_lookup_notify(ipc_space_t, mach_port_t);
extern ipc_port_t
-ipc_port_make_send(/* ipc_port_t */);
+ipc_port_make_send(ipc_port_t);
extern ipc_port_t
-ipc_port_copy_send(/* ipc_port_t */);
+ipc_port_copy_send(ipc_port_t);
extern mach_port_t
-ipc_port_copyout_send(/* ipc_port_t, ipc_space_t */);
+ipc_port_copyout_send(ipc_port_t, ipc_space_t);
extern void
-ipc_port_release_send(/* ipc_port_t */);
+ipc_port_release_send(ipc_port_t);
extern ipc_port_t
-ipc_port_make_sonce(/* ipc_port_t */);
+ipc_port_make_sonce(ipc_port_t);
extern void
-ipc_port_release_sonce(/* ipc_port_t */);
+ipc_port_release_sonce(ipc_port_t);
extern void
-ipc_port_release_receive(/* ipc_port_t */);
+ipc_port_release_receive(ipc_port_t);
extern ipc_port_t
-ipc_port_alloc_special(/* ipc_space_t */);
+ipc_port_alloc_special(ipc_space_t);
extern void
-ipc_port_dealloc_special(/* ipc_port_t */);
+ipc_port_dealloc_special(ipc_port_t, ipc_space_t);
#define ipc_port_alloc_kernel() \
ipc_port_alloc_special(ipc_space_kernel)
@@ -327,6 +326,6 @@ ipc_port_dealloc_special(/* ipc_port_t */);
ipc_object_release(&(port)->ip_object)
extern void
-ipc_port_print(/* ipc_port_t */);
+ipc_port_print(ipc_port_t);
#endif /* _IPC_IPC_PORT_H_ */
diff --git a/ipc/ipc_pset.h b/ipc/ipc_pset.h
index e6cdd5b..ac984f9 100644
--- a/ipc/ipc_pset.h
+++ b/ipc/ipc_pset.h
@@ -66,22 +66,22 @@ typedef struct ipc_pset {
#define ips_release(pset) io_release(&(pset)->ips_object)
extern kern_return_t
-ipc_pset_alloc(/* ipc_space_t, mach_port_t *, ipc_pset_t * */);
+ipc_pset_alloc(ipc_space_t, mach_port_t *, ipc_pset_t *);
extern kern_return_t
-ipc_pset_alloc_name(/* ipc_space_t, mach_port_t, ipc_pset_t * */);
+ipc_pset_alloc_name(ipc_space_t, mach_port_t, ipc_pset_t *);
extern void
-ipc_pset_add(/* ipc_pset_t, ipc_port_t */);
+ipc_pset_add(ipc_pset_t, ipc_port_t);
extern void
-ipc_pset_remove(/* ipc_pset_t, ipc_port_t */);
+ipc_pset_remove(ipc_pset_t, ipc_port_t);
extern kern_return_t
-ipc_pset_move(/* ipc_space_t, mach_port_t, mach_port_t */);
+ipc_pset_move(ipc_space_t, ipc_port_t, ipc_pset_t);
extern void
-ipc_pset_destroy(/* ipc_pset_t */);
+ipc_pset_destroy(ipc_pset_t);
#define ipc_pset_reference(pset) \
ipc_object_reference(&(pset)->ips_object)
@@ -90,6 +90,6 @@ ipc_pset_destroy(/* ipc_pset_t */);
ipc_object_release(&(pset)->ips_object)
extern void
-ipc_pset_print(/* ipc_pset_t */);
+ipc_pset_print(ipc_pset_t);
#endif /* _IPC_IPC_PSET_H_ */
diff --git a/ipc/ipc_right.h b/ipc/ipc_right.h
index fe0a088..03642f8 100644
--- a/ipc/ipc_right.h
+++ b/ipc/ipc_right.h
@@ -38,74 +38,75 @@
#include <mach/boolean.h>
#include <mach/kern_return.h>
+#include <ipc/ipc_entry.h>
#include <ipc/ipc_port.h>
#define ipc_right_lookup_read ipc_right_lookup_write
extern kern_return_t
-ipc_right_lookup_write(/* ipc_space_t, mach_port_t, ipc_entry_t * */);
+ipc_right_lookup_write(ipc_space_t, mach_port_t, ipc_entry_t *);
extern boolean_t
-ipc_right_reverse(/* ipc_space_t, ipc_object_t,
- mach_port_t *, ipc_entry_t * */);
+ipc_right_reverse(ipc_space_t, ipc_object_t,
+ mach_port_t *, ipc_entry_t *);
extern kern_return_t
-ipc_right_dnrequest(/* ipc_space_t, mach_port_t, boolean_t,
- ipc_port_t, ipc_port_t * */);
+ipc_right_dnrequest(ipc_space_t, mach_port_t, boolean_t,
+ ipc_port_t, ipc_port_t *);
extern ipc_port_t
-ipc_right_dncancel(/* ipc_space_t, ipc_port_t, mach_port_t, ipc_entry_t */);
+ipc_right_dncancel(ipc_space_t, ipc_port_t, mach_port_t, ipc_entry_t);
#define ipc_right_dncancel_macro(space, port, name, entry) \
(((entry)->ie_request == 0) ? IP_NULL : \
ipc_right_dncancel((space), (port), (name), (entry)))
extern boolean_t
-ipc_right_inuse(/* ipc_space_t, mach_port_t, ipc_entry_t */);
+ipc_right_inuse(ipc_space_t, mach_port_t, ipc_entry_t);
extern boolean_t
-ipc_right_check(/* ipc_space_t, mach_port_t, ipc_entry_t, ipc_port_t */);
+ipc_right_check(ipc_space_t, ipc_port_t, mach_port_t, ipc_entry_t);
extern void
-ipc_right_clean(/* ipc_space_t, mach_port_t, ipc_entry_t */);
+ipc_right_clean(ipc_space_t, mach_port_t, ipc_entry_t);
extern kern_return_t
-ipc_right_destroy(/* ipc_space_t, mach_port_t, ipc_entry_t */);
+ipc_right_destroy(ipc_space_t, mach_port_t, ipc_entry_t);
extern kern_return_t
-ipc_right_dealloc(/* ipc_space_t, mach_port_t, ipc_entry_t */);
+ipc_right_dealloc(ipc_space_t, mach_port_t, ipc_entry_t);
extern kern_return_t
-ipc_right_delta(/* ipc_space_t, mach_port_t, ipc_entry_t,
- mach_port_right_t, mach_port_delta_t */);
+ipc_right_delta(ipc_space_t, mach_port_t, ipc_entry_t,
+ mach_port_right_t, mach_port_delta_t);
extern kern_return_t
-ipc_right_info(/* ipc_space_t, mach_port_t, ipc_entry_t,
- mach_port_type_t *, mach_port_urefs_t * */);
+ipc_right_info(ipc_space_t, mach_port_t, ipc_entry_t,
+ mach_port_type_t *, mach_port_urefs_t *);
extern boolean_t
-ipc_right_copyin_check(/* ipc_space_t, mach_port_t, ipc_entry_t,
- mach_msg_type_name_t */);
+ipc_right_copyin_check(ipc_space_t, mach_port_t, ipc_entry_t,
+ mach_msg_type_name_t);
extern kern_return_t
-ipc_right_copyin(/* ipc_space_t, mach_port_t, ipc_entry_t,
- mach_msg_type_name_t, boolean_t,
- ipc_object_t *, ipc_port_t * */);
+ipc_right_copyin(ipc_space_t, mach_port_t, ipc_entry_t,
+ mach_msg_type_name_t, boolean_t,
+ ipc_object_t *, ipc_port_t *);
extern void
-ipc_right_copyin_undo(/* ipc_space_t, mach_port_t, ipc_entry_t,
- mach_msg_type_name_t, ipc_object_t, ipc_port_t */);
+ipc_right_copyin_undo(ipc_space_t, mach_port_t, ipc_entry_t,
+ mach_msg_type_name_t, ipc_object_t, ipc_port_t);
extern kern_return_t
-ipc_right_copyin_two(/* ipc_space_t, mach_port_t, ipc_entry_t,
- ipc_object_t *, ipc_port_t * */);
+ipc_right_copyin_two(ipc_space_t, mach_port_t, ipc_entry_t,
+ ipc_object_t *, ipc_port_t *);
extern kern_return_t
-ipc_right_copyout(/* ipc_space_t, mach_port_t, ipc_entry_t,
- mach_msg_type_name_t, boolean_t, ipc_object_t */);
+ipc_right_copyout(ipc_space_t, mach_port_t, ipc_entry_t,
+ mach_msg_type_name_t, boolean_t, ipc_object_t);
extern kern_return_t
-ipc_right_rename(/* ipc_space_t, mach_port_t, ipc_entry_t,
- mach_port_t, ipc_entry_t */);
+ipc_right_rename(ipc_space_t, mach_port_t, ipc_entry_t,
+ mach_port_t, ipc_entry_t);
#endif /* _IPC_IPC_RIGHT_H_ */
diff --git a/ipc/ipc_space.h b/ipc/ipc_space.h
index 50f5d5e..d030bf7 100644
--- a/ipc/ipc_space.h
+++ b/ipc/ipc_space.h
@@ -41,9 +41,11 @@
#include <mach/boolean.h>
#include <mach/kern_return.h>
+#include <mach/mach_types.h>
#include <kern/macro_help.h>
#include <kern/lock.h>
#include <ipc/ipc_splay.h>
+#include <ipc/ipc_types.h>
/*
* Every task has a space of IPC capabilities.
@@ -128,7 +130,7 @@ extern void ipc_space_release(struct ipc_space *space);
#define is_reference(is) ipc_space_reference(is)
#define is_release(is) ipc_space_release(is)
-kern_return_t ipc_space_create(/* ipc_table_size_t, ipc_space_t * */);
+kern_return_t ipc_space_create(ipc_table_size_t, ipc_space_t *);
kern_return_t ipc_space_create_special(struct ipc_space **);
void ipc_space_destroy(struct ipc_space *);
diff --git a/ipc/ipc_table.h b/ipc/ipc_table.h
index 3bfcc46..695adae 100644
--- a/ipc/ipc_table.h
+++ b/ipc/ipc_table.h
@@ -81,7 +81,7 @@ extern ipc_table_size_t ipc_table_entries;
extern ipc_table_size_t ipc_table_dnrequests;
extern void
-ipc_table_init();
+ipc_table_init(void);
/*
* Note that ipc_table_alloc, ipc_table_realloc, and ipc_table_free
diff --git a/ipc/mach_msg.c b/ipc/mach_msg.c
index ddb277c..e6bcf61 100644
--- a/ipc/mach_msg.c
+++ b/ipc/mach_msg.c
@@ -283,7 +283,7 @@ mach_msg_receive(msg, option, rcv_size, rcv_name, time_out, notify)
*/
void
-mach_msg_receive_continue()
+mach_msg_receive_continue(void)
{
ipc_thread_t self = current_thread();
ipc_space_t space = current_space();
@@ -1673,7 +1673,7 @@ mach_msg_trap(msg, option, send_size, rcv_size, rcv_name, time_out, notify)
*/
void
-mach_msg_continue()
+mach_msg_continue(void)
{
ipc_thread_t thread = current_thread();
task_t task = thread->task;
diff --git a/ipc/mach_msg.h b/ipc/mach_msg.h
index f7d22e3..ce0fe4d 100644
--- a/ipc/mach_msg.h
+++ b/ipc/mach_msg.h
@@ -40,21 +40,21 @@
#include <mach/message.h>
extern mach_msg_return_t
-mach_msg_send(/* mach_msg_header_t *, mach_msg_option_t,
- mach_msg_size_t, mach_msg_timeout_t, mach_port_t */);
+mach_msg_send(mach_msg_header_t *, mach_msg_option_t,
+ mach_msg_size_t, mach_msg_timeout_t, mach_port_t);
extern mach_msg_return_t
-mach_msg_receive(/* mach_msg_header_t *, mach_msg_option_t,
- mach_msg_size_t, mach_port_t,
- mach_msg_timeout_t, mach_port_t */);
+mach_msg_receive(mach_msg_header_t *, mach_msg_option_t,
+ mach_msg_size_t, mach_port_t,
+ mach_msg_timeout_t, mach_port_t);
extern void
-mach_msg_receive_continue();
+mach_msg_receive_continue(void);
extern void
-mach_msg_continue();
+mach_msg_continue(void);
extern boolean_t
-mach_msg_interrupt(/* thread_t */);
+mach_msg_interrupt(thread_t);
#endif /* _IPC_MACH_MSG_H_ */