diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c index 7d7abc0d47b981d8231f807f59914c4c7da0affa..b929fe20198117683629629616bdcb0a1a7b02bd 100644 --- a/fs/btrfs/extent-tree.c +++ b/fs/btrfs/extent-tree.c @@ -4419,7 +4419,7 @@ static int should_alloc_chunk(struct btrfs_fs_info *fs_info, { struct btrfs_block_rsv *global_rsv = &fs_info->global_block_rsv; u64 num_bytes = sinfo->total_bytes - sinfo->bytes_readonly; - u64 num_allocated = sinfo->bytes_used + sinfo->bytes_reserved; + u64 num_allocated = sinfo->bytes_used + sinfo->bytes_reserved + sinfo->bytes_pinned; u64 thresh; if (force == CHUNK_ALLOC_FORCE)