diff options
author | Josef Bacik <josef@redhat.com> | 2011-08-19 12:06:12 -0400 |
---|---|---|
committer | Josef Bacik <josef@redhat.com> | 2011-10-19 15:12:38 -0400 |
commit | a9b5fcddce594a408a48d523087b5bb64ce82469 (patch) | |
tree | b146a8c2c9a00012b253c94dc65baa8ecb325e61 /fs/btrfs/free-space-cache.c | |
parent | 482e6dc5261406fdb921946e70b51467b0305bad (diff) |
Btrfs: fix call to btrfs_search_slot in free space cache
We are setting ins_len to 1 even tho we are just modifying an item that should
be there already. This may cause the search stuff to split nodes on the way
down needelessly. Set this to 0 since we aren't inserting anything. Thanks,
Signed-off-by: Josef Bacik <josef@redhat.com>
Diffstat (limited to 'fs/btrfs/free-space-cache.c')
-rw-r--r-- | fs/btrfs/free-space-cache.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/free-space-cache.c b/fs/btrfs/free-space-cache.c index b0122e19db6b..701ef5951e3f 100644 --- a/fs/btrfs/free-space-cache.c +++ b/fs/btrfs/free-space-cache.c | |||
@@ -802,7 +802,7 @@ int __btrfs_write_out_cache(struct btrfs_root *root, struct inode *inode, | |||
802 | key.offset = offset; | 802 | key.offset = offset; |
803 | key.type = 0; | 803 | key.type = 0; |
804 | 804 | ||
805 | ret = btrfs_search_slot(trans, root, &key, path, 1, 1); | 805 | ret = btrfs_search_slot(trans, root, &key, path, 0, 1); |
806 | if (ret < 0) { | 806 | if (ret < 0) { |
807 | ret = -1; | 807 | ret = -1; |
808 | clear_extent_bit(&BTRFS_I(inode)->io_tree, 0, bytes - 1, | 808 | clear_extent_bit(&BTRFS_I(inode)->io_tree, 0, bytes - 1, |