(btrfs_test_opt(fs_info, FRAGMENT_DATA) &&
block_group->flags & BTRFS_BLOCK_GROUP_DATA);
}
+void btrfs_fragment_free_space(struct btrfs_block_group_cache *block_group);
#endif
struct btrfs_block_group_cache *btrfs_lookup_first_block_group(
}
#ifdef CONFIG_BTRFS_DEBUG
-static void fragment_free_space(struct btrfs_block_group_cache *block_group)
+void btrfs_fragment_free_space(struct btrfs_block_group_cache *block_group)
{
struct btrfs_fs_info *fs_info = block_group->fs_info;
u64 start = block_group->key.objectid;
block_group->space_info->bytes_used += bytes_used >> 1;
spin_unlock(&block_group->lock);
spin_unlock(&block_group->space_info->lock);
- fragment_free_space(block_group);
+ btrfs_fragment_free_space(block_group);
}
#endif
cache->space_info->bytes_used += bytes_used >> 1;
spin_unlock(&cache->lock);
spin_unlock(&cache->space_info->lock);
- fragment_free_space(cache);
+ btrfs_fragment_free_space(cache);
}
#endif
mutex_unlock(&caching_ctl->mutex);
u64 new_bytes_used = size - bytes_used;
bytes_used += new_bytes_used >> 1;
- fragment_free_space(cache);
+ btrfs_fragment_free_space(cache);
}
#endif
/*