[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 08/14] ipc/ipc_marequest.c: move struct definition to a header fi
From: |
Marin Ramesa |
Subject: |
[PATCH 08/14] ipc/ipc_marequest.c: move struct definition to a header file |
Date: |
Mon, 2 Dec 2013 22:54:46 +0100 |
* ipc/ipc_marequest.c (ipc_marequest_bucket): Move struct definition to
ipc/ipc_marequest.h.
* ipc/ipc_marequest.h: Include kern/lock.h.
---
ipc/ipc_marequest.c | 7 -------
ipc/ipc_marequest.h | 8 ++++++++
2 files changed, 8 insertions(+), 7 deletions(-)
diff --git a/ipc/ipc_marequest.c b/ipc/ipc_marequest.c
index 06c53eb..562083f 100644
--- a/ipc/ipc_marequest.c
+++ b/ipc/ipc_marequest.c
@@ -72,13 +72,6 @@ ipc_marequest_index_t ipc_marequest_mask;
MACH_PORT_INDEX(name) + MACH_PORT_NGEN(name)) & \
ipc_marequest_mask)
-typedef struct ipc_marequest_bucket {
- decl_simple_lock_data(, imarb_lock_data)
- ipc_marequest_t imarb_head;
-} *ipc_marequest_bucket_t;
-
-#define IMARB_NULL ((ipc_marequest_bucket_t) 0)
-
#define imarb_lock_init(imarb)
simple_lock_init(&(imarb)->imarb_lock_data)
#define imarb_lock(imarb) simple_lock(&(imarb)->imarb_lock_data)
#define imarb_unlock(imarb) simple_unlock(&(imarb)->imarb_lock_data)
diff --git a/ipc/ipc_marequest.h b/ipc/ipc_marequest.h
index 4f6f758..5000187 100644
--- a/ipc/ipc_marequest.h
+++ b/ipc/ipc_marequest.h
@@ -38,6 +38,7 @@
#include <mach/port.h>
#include <mach_debug/hash_info.h>
#include <ipc/ipc_types.h>
+#include <kern/lock.h>
/*
* A msg-accepted request is made when MACH_SEND_NOTIFY is used
@@ -72,6 +73,13 @@ typedef struct ipc_marequest {
#define IPC_MAREQUEST_SIZE 16
+typedef struct ipc_marequest_bucket {
+ decl_simple_lock_data(, imarb_lock_data)
+ ipc_marequest_t imarb_head;
+} *ipc_marequest_bucket_t;
+
+#define IMARB_NULL ((ipc_marequest_bucket_t) 0)
+
extern void
ipc_marequest_init(void);
--
1.8.1.4
- Re: [PATCH 03/14] ddb/db_cond.c: move struct definition to a header file, (continued)
[PATCH 04/14] ddb/db_macro.c: move struct definition to a header file, Marin Ramesa, 2013/12/02
[PATCH 05/14] i386/i386/idt.c: move struct definition to a header file, Marin Ramesa, 2013/12/02
[PATCH 06/14] i386/intel/pmap.c: move struct definitions to a header file, Marin Ramesa, 2013/12/02
[PATCH 07/14] ipc/ipc_hash.c: move struct definition to a header file, Marin Ramesa, 2013/12/02
[PATCH 08/14] ipc/ipc_marequest.c: move struct definition to a header file,
Marin Ramesa <=
[PATCH 09/14] ipc/ipc_port.c: trivial stylistic fix for consistency, Marin Ramesa, 2013/12/02
[PATCH 10/14] kern/act.c: move struct definition to a header file, Marin Ramesa, 2013/12/02
[PATCH 12/14] vm/memory_object_proxy.c: move struct definition to a header file, Marin Ramesa, 2013/12/02
[PATCH 11/14] kern/lock.c: move struct definition to a header file, Marin Ramesa, 2013/12/02
[PATCH 13/14] vm/vm_fault.c: move struct definition to a header file, Marin Ramesa, 2013/12/02