diff options
author | Chris Mason <chris.mason@oracle.com> | 2008-08-15 15:34:18 -0400 |
---|---|---|
committer | Chris Mason <chris.mason@oracle.com> | 2008-09-25 11:04:06 -0400 |
commit | 53863232ef961778aa414b700ed88a48e8e871e6 (patch) | |
tree | 05a74ac264a5fb4f6b8824771f5820ca5907afe5 /fs/btrfs/inode.c | |
parent | 4854ddd0ed0a687fc2d7c45a529c406232e31e7b (diff) |
Btrfs: Lower contention on the csum mutex
This takes the csum mutex deeper in the call chain and releases it
more often.
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/inode.c')
-rw-r--r-- | fs/btrfs/inode.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index 33b990878d84..65107894a5bb 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c | |||
@@ -415,10 +415,8 @@ static noinline int add_pending_csums(struct btrfs_trans_handle *trans, | |||
415 | btrfs_set_trans_block_group(trans, inode); | 415 | btrfs_set_trans_block_group(trans, inode); |
416 | list_for_each(cur, list) { | 416 | list_for_each(cur, list) { |
417 | sum = list_entry(cur, struct btrfs_ordered_sum, list); | 417 | sum = list_entry(cur, struct btrfs_ordered_sum, list); |
418 | mutex_lock(&BTRFS_I(inode)->csum_mutex); | ||
419 | btrfs_csum_file_blocks(trans, BTRFS_I(inode)->root, | 418 | btrfs_csum_file_blocks(trans, BTRFS_I(inode)->root, |
420 | inode, sum); | 419 | inode, sum); |
421 | mutex_unlock(&BTRFS_I(inode)->csum_mutex); | ||
422 | } | 420 | } |
423 | return 0; | 421 | return 0; |
424 | } | 422 | } |