aboutsummaryrefslogtreecommitdiffstats
path: root/fs/btrfs/transaction.h
diff options
context:
space:
mode:
authorYan Zheng <zheng.yan@oracle.com>2008-12-11 16:30:39 -0500
committerChris Mason <chris.mason@oracle.com>2008-12-11 16:30:39 -0500
commitd2fb3437e4d8d12c73c587615ad187d5288547ec (patch)
tree894e4c698970dd35226b2614b8a38fb8a96580e7 /fs/btrfs/transaction.h
parentcfc8ea87201dc9bb6aeb3fc80c61abee83e7cc06 (diff)
Btrfs: fix leaking block group on balance
The block group structs are referenced in many different places, and it's not safe to free while balancing. So, those block group structs were simply leaked instead. This patch replaces the block group pointer in the inode with the starting byte offset of the block group and adds reference counting to the block group struct. Signed-off-by: Yan Zheng <zheng.yan@oracle.com>
Diffstat (limited to 'fs/btrfs/transaction.h')
-rw-r--r--fs/btrfs/transaction.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/transaction.h b/fs/btrfs/transaction.h
index 202c8be6c05d..ffe7f639732b 100644
--- a/fs/btrfs/transaction.h
+++ b/fs/btrfs/transaction.h
@@ -41,7 +41,7 @@ struct btrfs_trans_handle {
41 unsigned long blocks_reserved; 41 unsigned long blocks_reserved;
42 unsigned long blocks_used; 42 unsigned long blocks_used;
43 struct btrfs_transaction *transaction; 43 struct btrfs_transaction *transaction;
44 struct btrfs_block_group_cache *block_group; 44 u64 block_group;
45 u64 alloc_exclude_start; 45 u64 alloc_exclude_start;
46 u64 alloc_exclude_nr; 46 u64 alloc_exclude_nr;
47}; 47};