[PATCH 16/19] MUTEX: IPC changes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The attached patch modifies the IPC files to use the new mutex functions.

Signed-Off-By: David Howells <[email protected]>
---
warthog>diffstat -p1 mutex-ipc-2615rc5.diff
 ipc/compat.c |    2 +-
 ipc/util.c   |    2 +-
 ipc/util.h   |    2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff -uNrp /warthog/kernels/linux-2.6.15-rc5/ipc/compat.c linux-2.6.15-rc5-mutex/ipc/compat.c
--- /warthog/kernels/linux-2.6.15-rc5/ipc/compat.c	2005-11-01 13:19:22.000000000 +0000
+++ linux-2.6.15-rc5-mutex/ipc/compat.c	2005-12-12 22:12:50.000000000 +0000
@@ -29,8 +29,8 @@
 #include <linux/shm.h>
 #include <linux/slab.h>
 #include <linux/syscalls.h>
+#include <linux/semaphore.h>
 
-#include <asm/semaphore.h>
 #include <asm/uaccess.h>
 
 #include "util.h"
diff -uNrp /warthog/kernels/linux-2.6.15-rc5/ipc/util.c linux-2.6.15-rc5-mutex/ipc/util.c
--- /warthog/kernels/linux-2.6.15-rc5/ipc/util.c	2005-12-08 16:23:55.000000000 +0000
+++ linux-2.6.15-rc5-mutex/ipc/util.c	2005-12-12 17:40:08.000000000 +0000
@@ -67,7 +67,7 @@ __initcall(ipc_init);
 void __init ipc_init_ids(struct ipc_ids* ids, int size)
 {
 	int i;
-	sema_init(&ids->sem,1);
+	init_MUTEX(&ids->sem);
 
 	if(size > IPCMNI)
 		size = IPCMNI;
diff -uNrp /warthog/kernels/linux-2.6.15-rc5/ipc/util.h linux-2.6.15-rc5-mutex/ipc/util.h
--- /warthog/kernels/linux-2.6.15-rc5/ipc/util.h	2005-11-01 13:19:22.000000000 +0000
+++ linux-2.6.15-rc5-mutex/ipc/util.h	2005-12-12 17:39:49.000000000 +0000
@@ -25,7 +25,7 @@ struct ipc_ids {
 	int max_id;
 	unsigned short seq;
 	unsigned short seq_max;
-	struct semaphore sem;	
+	struct mutex sem;	
 	struct ipc_id_ary nullentry;
 	struct ipc_id_ary* entries;
 };
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux