path: root/free-space-tree.h
Commit message (Collapse)AuthorAge
* btrfs-progs: Pull free space tree related code from kernelNikolay Borisov2018-10-25
| | | | | | | | | | | | To help implement free space tree checker in user space some kernel function are necessary, namely iterating/deleting/adding freespace items, some internal search functions. Functions to populate a block group based on the extent tree. The code is largely copy/paste from the kernel with locking eliminated (i.e free_space_lock). It supports reading/writing of both bitmap and extent based FST trees. Signed-off-by: Nikolay Borisov <> Signed-off-by: David Sterba <>
* btrfs-progs: add btrfs_clear_free_space_tree() from the kernelOmar Sandoval2016-11-23
| | | | | | Reviewed-by: Qu Wenruo <> Signed-off-by: Omar Sandoval <> Signed-off-by: David Sterba <>
* btrfs-progs: check the free space tree in btrfsckOmar Sandoval2016-01-12
This reuses the existing code for checking the free space cache, we just need to load the free space tree. While we do that, we check a couple of invariants on the free space tree itself. This requires pulling in some code from the kernel to exclude the super stripes. Signed-off-by: Omar Sandoval <> Signed-off-by: David Sterba <>