summaryrefslogtreecommitdiff
path: root/fs/btrfs/transaction.c
diff options
context:
space:
mode:
authorChris Mason <chris.mason@oracle.com>2007-10-15 16:18:14 -0400
committerChris Mason <chris.mason@oracle.com>2008-09-25 11:03:56 -0400
commit4dc119046d0d8501afa4346472917fb05586ad9c (patch)
tree712c98f8f66aa1e83020574a19d015df88c5024e /fs/btrfs/transaction.c
parente19caa5f0e34b571ed0c2617554af5c43cb124d1 (diff)
downloadlwn-4dc119046d0d8501afa4346472917fb05586ad9c.tar.gz
lwn-4dc119046d0d8501afa4346472917fb05586ad9c.zip
Btrfs: Add an extent buffer LRU to reduce radix tree hits
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/transaction.c')
-rw-r--r--fs/btrfs/transaction.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/fs/btrfs/transaction.c b/fs/btrfs/transaction.c
index 87456ab74275..67e4aca36a62 100644
--- a/fs/btrfs/transaction.c
+++ b/fs/btrfs/transaction.c
@@ -443,8 +443,7 @@ static int drop_dirty_roots(struct btrfs_root *tree_root,
BUG_ON(ret);
mutex_unlock(&tree_root->fs_info->fs_mutex);
btrfs_btree_balance_dirty(tree_root, nr);
- schedule();
-
+ cond_resched();
mutex_lock(&tree_root->fs_info->fs_mutex);
}
BUG_ON(ret);
@@ -471,7 +470,7 @@ static int drop_dirty_roots(struct btrfs_root *tree_root,
mutex_unlock(&tree_root->fs_info->fs_mutex);
btrfs_btree_balance_dirty(tree_root, nr);
- schedule();
+ cond_resched();
}
return ret;
}