diff options
author | Omar Sandoval <osandov@fb.com> | 2015-09-29 20:51:45 -0700 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2016-01-12 15:02:54 +0100 |
commit | e4797df6a9fac329fdb168f8fd6bf1925ead3c28 (patch) | |
tree | b654c6f772fa2506638c8a3d3dae0a5bbe32d6a1 /free-space-cache.h | |
parent | d8c537e71f3dce8a8d03dddfcbcac71ef2e2cdc4 (diff) |
btrfs-progs: check the free space tree in btrfsck
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 <osandov@fb.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'free-space-cache.h')
-rw-r--r-- | free-space-cache.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/free-space-cache.h b/free-space-cache.h index 85411a10..9214077a 100644 --- a/free-space-cache.h +++ b/free-space-cache.h @@ -57,4 +57,6 @@ int btrfs_init_free_space_ctl(struct btrfs_block_group_cache *block_group, int sectorsize); void unlink_free_space(struct btrfs_free_space_ctl *ctl, struct btrfs_free_space *info); +int btrfs_add_free_space(struct btrfs_free_space_ctl *ctl, u64 offset, + u64 bytes); #endif |