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/ocfs2/localalloc.c | |
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/ocfs2/localalloc.c')
-rw-r--r-- | fs/ocfs2/localalloc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/ocfs2/localalloc.c b/fs/ocfs2/localalloc.c index fe373a2101d9..149b35181666 100644 --- a/fs/ocfs2/localalloc.c +++ b/fs/ocfs2/localalloc.c | |||
@@ -334,7 +334,7 @@ int ocfs2_begin_local_alloc_recovery(struct ocfs2_super *osb, | |||
334 | goto bail; | 334 | goto bail; |
335 | } | 335 | } |
336 | 336 | ||
337 | down(&inode->i_sem); | 337 | mutex_lock(&inode->i_mutex); |
338 | 338 | ||
339 | status = ocfs2_read_block(osb, OCFS2_I(inode)->ip_blkno, | 339 | status = ocfs2_read_block(osb, OCFS2_I(inode)->ip_blkno, |
340 | &alloc_bh, 0, inode); | 340 | &alloc_bh, 0, inode); |
@@ -367,7 +367,7 @@ bail: | |||
367 | brelse(alloc_bh); | 367 | brelse(alloc_bh); |
368 | 368 | ||
369 | if (inode) { | 369 | if (inode) { |
370 | up(&inode->i_sem); | 370 | mutex_unlock(&inode->i_mutex); |
371 | iput(inode); | 371 | iput(inode); |
372 | } | 372 | } |
373 | 373 | ||
@@ -446,7 +446,7 @@ bail: | |||
446 | 446 | ||
447 | /* | 447 | /* |
448 | * make sure we've got at least bitswanted contiguous bits in the | 448 | * make sure we've got at least bitswanted contiguous bits in the |
449 | * local alloc. You lose them when you drop i_sem. | 449 | * local alloc. You lose them when you drop i_mutex. |
450 | * | 450 | * |
451 | * We will add ourselves to the transaction passed in, but may start | 451 | * We will add ourselves to the transaction passed in, but may start |
452 | * our own in order to shift windows. | 452 | * our own in order to shift windows. |