Lines Matching refs:cluster_size

142     return off / s->cluster_size;  in host_cluster_index()
219 s->used_bmap_size = DIV_ROUND_UP(payload_bytes, s->cluster_size); in parallels_fill_used_bitmap()
282 int64_t bytes = to_allocate * s->cluster_size; in allocate_clusters()
307 new_usedsize = s->used_bmap_size + bytes / s->cluster_size; in allocate_clusters()
322 host_off += first_free * s->cluster_size; in allocate_clusters()
332 s->cluster_size * to_allocate, 0); in allocate_clusters()
376 host_off += s->cluster_size; in allocate_clusters()
552 if (!QEMU_IS_ALIGNED(offset, s->cluster_size)) { in parallels_co_pdiscard()
554 } else if (!QEMU_IS_ALIGNED(bytes, s->cluster_size)) { in parallels_co_pdiscard()
558 cluster = offset / s->cluster_size; in parallels_co_pdiscard()
559 count = bytes / s->cluster_size; in parallels_co_pdiscard()
568 ret = bdrv_co_pdiscard(bs->file, host_off, s->cluster_size); in parallels_co_pdiscard()
636 min_off = ROUND_UP(min_off, s->cluster_size / BDRV_SECTOR_SIZE); in parallels_test_data_off()
716 if (off + s->cluster_size > size) { in parallels_check_outside_image()
734 res->image_end_offset = high_off + s->cluster_size; in parallels_check_outside_image()
757 count = DIV_ROUND_UP(size - res->image_end_offset, s->cluster_size); in parallels_check_leak()
814 if (res->image_end_offset % s->cluster_size) { in parallels_check_duplicate()
821 buf = qemu_blockalign(bs, s->cluster_size); in parallels_check_duplicate()
856 ret = bdrv_co_pread(bs->file, host_off, s->cluster_size, buf, 0); in parallels_check_duplicate()
862 guest_sector = (i * (int64_t)s->cluster_size) >> BDRV_SECTOR_BITS; in parallels_check_duplicate()
870 ret = bdrv_co_pwrite(bs->file, host_off, s->cluster_size, buf, 0); in parallels_check_duplicate()
876 if (host_off + s->cluster_size > res->image_end_offset) { in parallels_check_duplicate()
877 res->image_end_offset = host_off + s->cluster_size; in parallels_check_duplicate()
940 if (off == 0 || off + s->cluster_size > res->image_end_offset) { in parallels_collect_statistics()
945 if (prev_off != 0 && (prev_off + s->cluster_size) != off) { in parallels_collect_statistics()
1014 cl_size = parallels_opts->cluster_size; in parallels_co_create()
1152 create_options->u.parallels.cluster_size = in parallels_co_create_opts()
1153 ROUND_UP(create_options->u.parallels.cluster_size, BDRV_SECTOR_SIZE); in parallels_co_create_opts()
1294 s->cluster_size = s->tracks << BDRV_SECTOR_BITS; in parallels_open()