diff options
author | Jes Sorensen <jes@sgi.com> | 2006-01-09 18:59:24 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@hera.kernel.org> | 2006-01-09 18:59:24 -0500 |
commit | 1b1dcc1b57a49136f118a0f16367256ff9994a69 (patch) | |
tree | b0b36d4f41d28c9d6514fb309d33c1a084d6309b /fs/exportfs | |
parent | 794ee1baee1c26be40410233e6c20bceb2b03c08 (diff) |
[PATCH] mutex subsystem, semaphore to mutex: VFS, ->i_sem
This patch converts the inode semaphore to a mutex. I have tested it on
XFS and compiled as much as one can consider on an ia64. Anyway your
luck with it might be different.
Modified-by: Ingo Molnar <mingo@elte.hu>
(finished the conversion)
Signed-off-by: Jes Sorensen <jes@sgi.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'fs/exportfs')
-rw-r--r-- | fs/exportfs/expfs.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/fs/exportfs/expfs.c b/fs/exportfs/expfs.c index c49d6254379a..5bfe40085fbc 100644 --- a/fs/exportfs/expfs.c +++ b/fs/exportfs/expfs.c | |||
@@ -177,9 +177,9 @@ find_exported_dentry(struct super_block *sb, void *obj, void *parent, | |||
177 | struct dentry *ppd; | 177 | struct dentry *ppd; |
178 | struct dentry *npd; | 178 | struct dentry *npd; |
179 | 179 | ||
180 | down(&pd->d_inode->i_sem); | 180 | mutex_lock(&pd->d_inode->i_mutex); |
181 | ppd = CALL(nops,get_parent)(pd); | 181 | ppd = CALL(nops,get_parent)(pd); |
182 | up(&pd->d_inode->i_sem); | 182 | mutex_unlock(&pd->d_inode->i_mutex); |
183 | 183 | ||
184 | if (IS_ERR(ppd)) { | 184 | if (IS_ERR(ppd)) { |
185 | err = PTR_ERR(ppd); | 185 | err = PTR_ERR(ppd); |
@@ -201,9 +201,9 @@ find_exported_dentry(struct super_block *sb, void *obj, void *parent, | |||
201 | break; | 201 | break; |
202 | } | 202 | } |
203 | dprintk("find_exported_dentry: found name: %s\n", nbuf); | 203 | dprintk("find_exported_dentry: found name: %s\n", nbuf); |
204 | down(&ppd->d_inode->i_sem); | 204 | mutex_lock(&ppd->d_inode->i_mutex); |
205 | npd = lookup_one_len(nbuf, ppd, strlen(nbuf)); | 205 | npd = lookup_one_len(nbuf, ppd, strlen(nbuf)); |
206 | up(&ppd->d_inode->i_sem); | 206 | mutex_unlock(&ppd->d_inode->i_mutex); |
207 | if (IS_ERR(npd)) { | 207 | if (IS_ERR(npd)) { |
208 | err = PTR_ERR(npd); | 208 | err = PTR_ERR(npd); |
209 | dprintk("find_exported_dentry: lookup failed: %d\n", err); | 209 | dprintk("find_exported_dentry: lookup failed: %d\n", err); |
@@ -242,9 +242,9 @@ find_exported_dentry(struct super_block *sb, void *obj, void *parent, | |||
242 | struct dentry *nresult; | 242 | struct dentry *nresult; |
243 | err = CALL(nops,get_name)(target_dir, nbuf, result); | 243 | err = CALL(nops,get_name)(target_dir, nbuf, result); |
244 | if (!err) { | 244 | if (!err) { |
245 | down(&target_dir->d_inode->i_sem); | 245 | mutex_lock(&target_dir->d_inode->i_mutex); |
246 | nresult = lookup_one_len(nbuf, target_dir, strlen(nbuf)); | 246 | nresult = lookup_one_len(nbuf, target_dir, strlen(nbuf)); |
247 | up(&target_dir->d_inode->i_sem); | 247 | mutex_unlock(&target_dir->d_inode->i_mutex); |
248 | if (!IS_ERR(nresult)) { | 248 | if (!IS_ERR(nresult)) { |
249 | if (nresult->d_inode) { | 249 | if (nresult->d_inode) { |
250 | dput(result); | 250 | dput(result); |