]> www.infradead.org Git - users/jedix/linux-maple.git/commit
Btrfs: use the transactions block_rsv for the csum root
authorJosef Bacik <josef@redhat.com>
Tue, 30 Aug 2011 15:31:29 +0000 (11:31 -0400)
committerChris Mason <chris.mason@oracle.com>
Wed, 16 Nov 2011 02:20:20 +0000 (21:20 -0500)
commit2711181288fa027a6b94312de4c6ab0b0ec05068
tree1dff84e7c6c2dc91e4a62991800b55ba28820827
parentcdcd963fac0d3b35236780c3755f71ac661dfbe0
Btrfs: use the transactions block_rsv for the csum root

The alloc warnings everybody has been seeing is because we have been reserving
space for csums, but we weren't actually using that space.  So make
get_block_rsv() return the trans->block_rsv if we're modifying the csum root.
Also set the trans->block_rsv to NULL so that if we modify the csum root when
running delayed ref's that comes out of the global reserve like it's supposed
to.  With this patch I'm not seeing those alloc warnings anymore.  Thanks,

Signed-off-by: Josef Bacik <josef@redhat.com>
(cherry picked from commit 4c13d758b7e79c14a0026c1f783f0c79e339b7bb)
fs/btrfs/extent-tree.c
fs/btrfs/transaction.c