diff options
author | Wang Shilong <wangsl.fnst@cn.fujitsu.com> | 2014-02-19 06:24:18 -0500 |
---|---|---|
committer | Josef Bacik <jbacik@fb.com> | 2014-03-10 15:16:54 -0400 |
commit | c0af8f0b1cf7ec5cde4450be9f8bfeb8c211d40a (patch) | |
tree | 8eeabebfd1e6c6d10ae6145936052b38a22e4077 /fs/btrfs | |
parent | 12cf93728dfba237b46001a95479829c7179cdc9 (diff) |
Btrfs: cancel scrub on transaction abortion
If we fail to commit transaction, we'd better
cancel scrub operations.
Suggested-by: Miao Xie <miaox@cn.fujitsu.com>
Signed-off-by: Wang Shilong <wangsl.fnst@cn.fujitsu.com>
Signed-off-by: Josef Bacik <jbacik@fb.com>
Diffstat (limited to 'fs/btrfs')
-rw-r--r-- | fs/btrfs/transaction.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/btrfs/transaction.c b/fs/btrfs/transaction.c index 84da6669f384..79a4186b724a 100644 --- a/fs/btrfs/transaction.c +++ b/fs/btrfs/transaction.c | |||
@@ -1580,6 +1580,7 @@ static void cleanup_transaction(struct btrfs_trans_handle *trans, | |||
1580 | 1580 | ||
1581 | if (current->journal_info == trans) | 1581 | if (current->journal_info == trans) |
1582 | current->journal_info = NULL; | 1582 | current->journal_info = NULL; |
1583 | btrfs_scrub_cancel(root->fs_info); | ||
1583 | 1584 | ||
1584 | kmem_cache_free(btrfs_trans_handle_cachep, trans); | 1585 | kmem_cache_free(btrfs_trans_handle_cachep, trans); |
1585 | } | 1586 | } |