]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
Btrfs: remove btrfs_end_transaction_dmeta()
authorMiao Xie <miaox@cn.fujitsu.com>
Thu, 26 Dec 2013 05:07:04 +0000 (13:07 +0800)
committerChris Mason <clm@fb.com>
Tue, 28 Jan 2014 21:20:08 +0000 (13:20 -0800)
Two reasons:
- btrfs_end_transaction_dmeta() is the same as btrfs_end_transaction_throttle()
  so it is unnecessary.
- All the delayed items should be dealt in the current transaction, so the
  workers should not commit the transaction, instead, deal with the delayed
  items as many as possible.

So we can remove btrfs_end_transaction_dmeta()

Signed-off-by: Miao Xie <miaox@cn.fujitsu.com>
Signed-off-by: Chris Mason <clm@fb.com>
fs/btrfs/delayed-inode.c
fs/btrfs/transaction.c
fs/btrfs/transaction.h

index 6b2013403f46265f5e2fa4794d125111a8c6b288..826a26053c70942c7e129d1b2482e7d8498df8f1 100644 (file)
@@ -1302,7 +1302,7 @@ again:
        __btrfs_commit_inode_delayed_items(trans, path, delayed_node);
 
        trans->block_rsv = block_rsv;
-       btrfs_end_transaction_dmeta(trans, root);
+       btrfs_end_transaction(trans, root);
        btrfs_btree_balance_dirty_nodelay(root);
 
 release_path:
index 46bfd820d91f49e0fbebddbcf067299dcd2b679f..e5fe801659ba8389b0c912baed19e39ea15655c4 100644 (file)
@@ -790,12 +790,6 @@ int btrfs_end_transaction_throttle(struct btrfs_trans_handle *trans,
        return __btrfs_end_transaction(trans, root, 1);
 }
 
-int btrfs_end_transaction_dmeta(struct btrfs_trans_handle *trans,
-                               struct btrfs_root *root)
-{
-       return __btrfs_end_transaction(trans, root, 1);
-}
-
 /*
  * when btree blocks are allocated, they have some corresponding bits set for
  * them in one of two extent_io trees.  This is used to make sure all of
index 7657d115067d3f8ae1d5cc39a53410d8a1011673..d05b6013fea88192aa63efa1bb73868b7f8dc69a 100644 (file)
@@ -154,8 +154,6 @@ int btrfs_commit_transaction_async(struct btrfs_trans_handle *trans,
                                   int wait_for_unblock);
 int btrfs_end_transaction_throttle(struct btrfs_trans_handle *trans,
                                   struct btrfs_root *root);
-int btrfs_end_transaction_dmeta(struct btrfs_trans_handle *trans,
-                               struct btrfs_root *root);
 int btrfs_should_end_transaction(struct btrfs_trans_handle *trans,
                                 struct btrfs_root *root);
 void btrfs_throttle(struct btrfs_root *root);