]> git.baikalelectronics.ru Git - kernel.git/commit
Btrfs: release trans metadata bytes before flushing delayed refs
authorJosef Bacik <josef@redhat.com>
Fri, 14 Oct 2011 18:40:17 +0000 (14:40 -0400)
committerJosef Bacik <josef@redhat.com>
Wed, 19 Oct 2011 19:12:58 +0000 (15:12 -0400)
commitcb4d60f9e3ccf13526208025f344c6766b696514
treee7742796bf98c1211babe8d1bdc464ad3e3a98a1
parentb83d49cfbf0c8bb2e32a5fa107e45e596a6ad8f2
Btrfs: release trans metadata bytes before flushing delayed refs

We started setting trans->block_rsv = NULL to allow the delayed refs flushing
stuff to use the right block_rsv and then just made
btrfs_trans_release_metadata() unconditionally use the trans block rsv.  The
problem with this is we need to reserve some space in the transaction and then
migrate it to the global block rsv, so we need to be able to free that out
properly.  So instead just move btrfs_trans_release_metadata() before the
delayed ref flushing and use trans->block_rsv for the freeing.  Thanks,

Signed-off-by: Josef Bacik <josef@redhat.com>
fs/btrfs/extent-tree.c
fs/btrfs/transaction.c