• Home
  • Raw
  • Download

Lines Matching refs:cluster_offset

92     uint64_t cluster_offset;         // current write offset  member
458 static int get_whole_cluster(BlockDriverState *bs, uint64_t cluster_offset, in get_whole_cluster() argument
482 …if (bdrv_pwrite(act_s->hd, activeBDRV.cluster_offset << 9, whole_grain, sizeof(whole_grain)) != si… in get_whole_cluster()
515 uint64_t cluster_offset; in get_cluster_offset() local
556 cluster_offset = le32_to_cpu(l2_table[l2_index]); in get_cluster_offset()
558 if (!cluster_offset) { in get_cluster_offset()
563 cluster_offset = bdrv_getlength(s->hd); in get_cluster_offset()
564 bdrv_truncate(s->hd, cluster_offset + (s->cluster_sectors << 9)); in get_cluster_offset()
566 cluster_offset >>= 9; in get_cluster_offset()
567 tmp = cpu_to_le32(cluster_offset); in get_cluster_offset()
570 activeBDRV.cluster_offset = cluster_offset; in get_cluster_offset()
578 if (get_whole_cluster(bs, cluster_offset, offset, allocate) == -1) in get_cluster_offset()
589 cluster_offset <<= 9; in get_cluster_offset()
590 return cluster_offset; in get_cluster_offset()
598 uint64_t cluster_offset; in vmdk_is_allocated() local
600 cluster_offset = get_cluster_offset(bs, NULL, sector_num << 9, 0); in vmdk_is_allocated()
606 return (cluster_offset != 0); in vmdk_is_allocated()
614 uint64_t cluster_offset; in vmdk_read() local
617 cluster_offset = get_cluster_offset(bs, NULL, sector_num << 9, 0); in vmdk_read()
622 if (!cluster_offset) { in vmdk_read()
634 if(bdrv_pread(s->hd, cluster_offset + index_in_cluster * 512, buf, n * 512) != n * 512) in vmdk_read()
650 uint64_t cluster_offset; in vmdk_write() local
666 cluster_offset = get_cluster_offset(bs, &m_data, sector_num << 9, 1); in vmdk_write()
667 if (!cluster_offset) in vmdk_write()
670 if (bdrv_pwrite(s->hd, cluster_offset + index_in_cluster * 512, buf, n * 512) != n * 512) in vmdk_write()