diff options
Diffstat (limited to 'fs/ocfs2/uptodate.c')
-rw-r--r-- | fs/ocfs2/uptodate.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/ocfs2/uptodate.c b/fs/ocfs2/uptodate.c index 50c8fb3de0a3..300b5bedfb21 100644 --- a/fs/ocfs2/uptodate.c +++ b/fs/ocfs2/uptodate.c | |||
@@ -388,7 +388,7 @@ out_free: | |||
388 | } | 388 | } |
389 | } | 389 | } |
390 | 390 | ||
391 | /* Item insertion is guarded by ip_io_sem, so the insertion path takes | 391 | /* Item insertion is guarded by ip_io_mutex, so the insertion path takes |
392 | * advantage of this by not rechecking for a duplicate insert during | 392 | * advantage of this by not rechecking for a duplicate insert during |
393 | * the slow case. Additionally, if the cache needs to be bumped up to | 393 | * the slow case. Additionally, if the cache needs to be bumped up to |
394 | * a tree, the code will not recheck after acquiring the lock -- | 394 | * a tree, the code will not recheck after acquiring the lock -- |
@@ -418,7 +418,7 @@ void ocfs2_set_buffer_uptodate(struct inode *inode, | |||
418 | (unsigned long long) bh->b_blocknr); | 418 | (unsigned long long) bh->b_blocknr); |
419 | 419 | ||
420 | /* No need to recheck under spinlock - insertion is guarded by | 420 | /* No need to recheck under spinlock - insertion is guarded by |
421 | * ip_io_sem */ | 421 | * ip_io_mutex */ |
422 | spin_lock(&oi->ip_lock); | 422 | spin_lock(&oi->ip_lock); |
423 | if (ocfs2_insert_can_use_array(oi, ci)) { | 423 | if (ocfs2_insert_can_use_array(oi, ci)) { |
424 | /* Fast case - it's an array and there's a free | 424 | /* Fast case - it's an array and there's a free |
@@ -440,7 +440,7 @@ void ocfs2_set_buffer_uptodate(struct inode *inode, | |||
440 | 440 | ||
441 | /* Called against a newly allocated buffer. Most likely nobody should | 441 | /* Called against a newly allocated buffer. Most likely nobody should |
442 | * be able to read this sort of metadata while it's still being | 442 | * be able to read this sort of metadata while it's still being |
443 | * allocated, but this is careful to take ip_io_sem anyway. */ | 443 | * allocated, but this is careful to take ip_io_mutex anyway. */ |
444 | void ocfs2_set_new_buffer_uptodate(struct inode *inode, | 444 | void ocfs2_set_new_buffer_uptodate(struct inode *inode, |
445 | struct buffer_head *bh) | 445 | struct buffer_head *bh) |
446 | { | 446 | { |
@@ -451,9 +451,9 @@ void ocfs2_set_new_buffer_uptodate(struct inode *inode, | |||
451 | 451 | ||
452 | set_buffer_uptodate(bh); | 452 | set_buffer_uptodate(bh); |
453 | 453 | ||
454 | down(&oi->ip_io_sem); | 454 | mutex_lock(&oi->ip_io_mutex); |
455 | ocfs2_set_buffer_uptodate(inode, bh); | 455 | ocfs2_set_buffer_uptodate(inode, bh); |
456 | up(&oi->ip_io_sem); | 456 | mutex_unlock(&oi->ip_io_mutex); |
457 | } | 457 | } |
458 | 458 | ||
459 | /* Requires ip_lock. */ | 459 | /* Requires ip_lock. */ |