]> git.openpandora.org Git - pandora-kernel.git/commitdiff
Btrfs: Introduce contexts for metadata reservation
authorYan, Zheng <zheng.yan@oracle.com>
Sun, 16 May 2010 14:46:25 +0000 (10:46 -0400)
committerChris Mason <chris.mason@oracle.com>
Tue, 25 May 2010 14:34:50 +0000 (10:34 -0400)
Introducing metadata reseravtion contexts has two major advantages.
First, it makes metadata reseravtion more traceable. Second, it can
reclaim freed space and re-add them to the itself after transaction
committed.

Besides add btrfs_block_rsv structure and related helper functions,
This patch contains following changes:

Move code that decides if freed tree block should be pinned into
btrfs_free_tree_block().

Make space accounting more accurate, mainly for handling read only
block groups.

Signed-off-by: Chris Mason <chris.mason@oracle.com>
fs/btrfs/ctree.c
fs/btrfs/ctree.h
fs/btrfs/disk-io.c
fs/btrfs/extent-tree.c
fs/btrfs/relocation.c
fs/btrfs/transaction.c
fs/btrfs/transaction.h

Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge