aboutsummaryrefslogtreecommitdiff
path: root/fs/btrfs/inode.c
diff options
context:
space:
mode:
authorChris Mason <chris.mason@oracle.com>2008-04-16 12:59:22 -0400
committerChris Mason <chris.mason@oracle.com>2008-09-25 11:04:01 -0400
commit699122f55904bec252ea4f8a64228ce98e3d9fda (patch)
tree3a3fc6f6026e6e40a1dd9639bc1090b1391daa29 /fs/btrfs/inode.c
parente015640f9c4fa2417dcc3bbbb3b2b61ad4059ab0 (diff)
Btrfs: Don't wait on tree block writeback before freeing them anymore
This isn't required anymore because we don't reallocate blocks that have already been written in this transaction. Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/inode.c')
-rw-r--r--fs/btrfs/inode.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c
index 3e1f21c632c..5632ea76007 100644
--- a/fs/btrfs/inode.c
+++ b/fs/btrfs/inode.c
@@ -383,9 +383,11 @@ int btrfs_readpage_io_hook(struct page *page, u64 start, u64 end)
struct btrfs_csum_item *item;
struct btrfs_path *path = NULL;
u32 csum;
+
if (btrfs_test_opt(root, NODATASUM) ||
btrfs_test_flag(inode, NODATASUM))
return 0;
+
mutex_lock(&root->fs_info->fs_mutex);
path = btrfs_alloc_path();
item = btrfs_lookup_csum(NULL, root, path, inode->i_ino, start, 0);