Re: [RFC PATCH v2 14/26] qcow2: Add subcluster support to qcow2_get_cluster_offset()

2019-11-11 Thread Max Reitz
On 08.11.19 16:42, Alberto Garcia wrote: > On Mon 04 Nov 2019 03:58:57 PM CET, Max Reitz wrote: [...] >>> @@ -514,8 +499,8 @@ int qcow2_get_cluster_offset(BlockDriverState *bs, >>> uint64_t offset, >> >> I suppose this is get_subcluster_offset now. > > Hmmm no, this returns the actual host clus

Re: [RFC PATCH v2 14/26] qcow2: Add subcluster support to qcow2_get_cluster_offset()

2019-11-08 Thread Alberto Garcia
On Mon 04 Nov 2019 03:58:57 PM CET, Max Reitz wrote: > OTOH, what I don’t like so far about this series is that the “cluster > logic” is still everywhere when I think it should just be about > subclusters now. (Except in few places where it must be about > clusters as in something that can have a

Re: [RFC PATCH v2 14/26] qcow2: Add subcluster support to qcow2_get_cluster_offset()

2019-11-04 Thread Max Reitz
On 26.10.19 23:25, Alberto Garcia wrote: > The logic of this function remains pretty much the same, except that > it uses count_contiguous_subclusters(), which combines the logic of > count_contiguous_clusters() / count_contiguous_clusters_unallocated() > and checks individual subclusters. > > Sig

[RFC PATCH v2 14/26] qcow2: Add subcluster support to qcow2_get_cluster_offset()

2019-10-26 Thread Alberto Garcia
The logic of this function remains pretty much the same, except that it uses count_contiguous_subclusters(), which combines the logic of count_contiguous_clusters() / count_contiguous_clusters_unallocated() and checks individual subclusters. Signed-off-by: Alberto Garcia --- block/qcow2-cluster.