diff options
author | Ingo Molnar <mingo@elte.hu> | 2006-03-26 04:37:12 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-03-26 11:56:55 -0500 |
commit | 353ab6e97b8f209dbecc9f650f1f84e3da2a7bb1 (patch) | |
tree | bffabd9a5a493ffd2b41dd825e71e848ca6ba6d7 /fs/nfsd | |
parent | e655a250d5fc12b6dfe0d436180ba4a3bfffdc9f (diff) |
[PATCH] sem2mutex: fs/
Semaphore to mutex conversion.
The conversion was generated via scripts, and the result was validated
automatically via a script as well.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Cc: Eric Van Hensbergen <ericvh@ericvh.myip.org>
Cc: Robert Love <rml@tech9.net>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: David Woodhouse <dwmw2@infradead.org>
Cc: Neil Brown <neilb@cse.unsw.edu.au>
Cc: Trond Myklebust <trond.myklebust@fys.uio.no>
Cc: Dave Kleikamp <shaggy@austin.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/nfsd')
-rw-r--r-- | fs/nfsd/nfs4state.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index f6ab762bea99..c7b87e92f91b 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c | |||
@@ -49,6 +49,7 @@ | |||
49 | #include <linux/nfsd/state.h> | 49 | #include <linux/nfsd/state.h> |
50 | #include <linux/nfsd/xdr4.h> | 50 | #include <linux/nfsd/xdr4.h> |
51 | #include <linux/namei.h> | 51 | #include <linux/namei.h> |
52 | #include <linux/mutex.h> | ||
52 | 53 | ||
53 | #define NFSDDBG_FACILITY NFSDDBG_PROC | 54 | #define NFSDDBG_FACILITY NFSDDBG_PROC |
54 | 55 | ||
@@ -77,11 +78,11 @@ static void nfs4_set_recdir(char *recdir); | |||
77 | 78 | ||
78 | /* Locking: | 79 | /* Locking: |
79 | * | 80 | * |
80 | * client_sema: | 81 | * client_mutex: |
81 | * protects clientid_hashtbl[], clientstr_hashtbl[], | 82 | * protects clientid_hashtbl[], clientstr_hashtbl[], |
82 | * unconfstr_hashtbl[], uncofid_hashtbl[]. | 83 | * unconfstr_hashtbl[], uncofid_hashtbl[]. |
83 | */ | 84 | */ |
84 | static DECLARE_MUTEX(client_sema); | 85 | static DEFINE_MUTEX(client_mutex); |
85 | 86 | ||
86 | static kmem_cache_t *stateowner_slab = NULL; | 87 | static kmem_cache_t *stateowner_slab = NULL; |
87 | static kmem_cache_t *file_slab = NULL; | 88 | static kmem_cache_t *file_slab = NULL; |
@@ -91,13 +92,13 @@ static kmem_cache_t *deleg_slab = NULL; | |||
91 | void | 92 | void |
92 | nfs4_lock_state(void) | 93 | nfs4_lock_state(void) |
93 | { | 94 | { |
94 | down(&client_sema); | 95 | mutex_lock(&client_mutex); |
95 | } | 96 | } |
96 | 97 | ||
97 | void | 98 | void |
98 | nfs4_unlock_state(void) | 99 | nfs4_unlock_state(void) |
99 | { | 100 | { |
100 | up(&client_sema); | 101 | mutex_unlock(&client_mutex); |
101 | } | 102 | } |
102 | 103 | ||
103 | static inline u32 | 104 | static inline u32 |