Skip to content

Commit

Permalink
Btrfs: don't wait around for new log writers on an SSD
Browse files Browse the repository at this point in the history
Waiting on spindles improves performance, but ssds want all the
IO as quickly as we can push it down.

Signed-off-by: Chris Mason <chris.mason@fusionio.com>
  • Loading branch information
Chris Mason committed Jul 23, 2012
1 parent 28a33cb commit e39e64a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion fs/btrfs/transaction.c
Original file line number Diff line number Diff line change
Expand Up @@ -1330,7 +1330,8 @@ int btrfs_commit_transaction(struct btrfs_trans_handle *trans,
spin_unlock(&root->fs_info->trans_lock);
}

if (now < cur_trans->start_time || now - cur_trans->start_time < 1)
if (!btrfs_test_opt(root, SSD) &&
(now < cur_trans->start_time || now - cur_trans->start_time < 1))
should_grow = 1;

do {
Expand Down

0 comments on commit e39e64a

Please sign in to comment.