Btrfs: Add BH_Defrag to mark buffers that are in need of defragging
This allows the tree walking code to defrag only the newly allocated buffers, it seems to be a good balance between perfect defragging and the performance hit of repeatedly reallocating blocks. Signed-off-by: Chris Mason <chris.mason@oracle.com>
This commit is contained in:

committed by
David Woodhouse

parent
e9d0b13b5b
commit
f2183bde1a
@@ -25,8 +25,10 @@
|
||||
|
||||
enum btrfs_bh_state_bits {
|
||||
BH_Checked = BH_PrivateStart,
|
||||
BH_Defrag,
|
||||
};
|
||||
BUFFER_FNS(Checked, checked);
|
||||
BUFFER_FNS(Defrag, defrag);
|
||||
|
||||
static inline struct btrfs_node *btrfs_buffer_node(struct buffer_head *bh)
|
||||
{
|
||||
|
Reference in New Issue
Block a user