diff options
author | Miao Xie <miaox@cn.fujitsu.com> | 2013-07-25 19:22:34 +0800 |
---|---|---|
committer | Chris Mason <chris.mason@fusionio.com> | 2013-09-01 08:04:33 -0400 |
commit | facc8a2247340a9735fe8cc123c5da2102f5ef1b (patch) | |
tree | fc6a1ea604e0bd5c3d22da891669e0516d776916 /fs/btrfs/disk-io.c | |
parent | f2a09da9d0cba17ad4041e7e54f1ca840b12d0be (diff) | |
download | blackbird-op-linux-facc8a2247340a9735fe8cc123c5da2102f5ef1b.tar.gz blackbird-op-linux-facc8a2247340a9735fe8cc123c5da2102f5ef1b.zip |
Btrfs: don't cache the csum value into the extent state tree
Before applying this patch, we cached the csum value into the extent state
tree when reading some data from the disk, this operation increased the lock
contention of the state tree.
Now, we just store the csum value into the bio structure or other unshared
structure, so we can reduce the lock contention.
Signed-off-by: Miao Xie <miaox@cn.fujitsu.com>
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
Signed-off-by: Chris Mason <chris.mason@fusionio.com>
Diffstat (limited to 'fs/btrfs/disk-io.c')
-rw-r--r-- | fs/btrfs/disk-io.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c index 56fcf8439f42..8e2eee67c3a8 100644 --- a/fs/btrfs/disk-io.c +++ b/fs/btrfs/disk-io.c @@ -576,8 +576,9 @@ static noinline int check_leaf(struct btrfs_root *root, return 0; } -static int btree_readpage_end_io_hook(struct page *page, u64 start, u64 end, - struct extent_state *state, int mirror) +static int btree_readpage_end_io_hook(struct btrfs_io_bio *io_bio, + u64 phy_offset, struct page *page, + u64 start, u64 end, int mirror) { struct extent_io_tree *tree; u64 found_start; |