On Mon, Sep 23, 2013 at 05:18:29PM +0800, Fam Zheng wrote:
> We use the extent size as cluster size for flat extents (where no L1/L2
> table is allocated so it's safe) reuse sector calculating code with
> sparse extents.
> 
> Don't pass in the cluster size for adding flat extent, just set it to
> sectors later, then the cluster size checking will not fail.

This is a little hacky, the next person that modifies vmdk may not be
aware of this trick.  I would avoid using ->cluster_sectors at all with
flat extents.  But I didn't investigate how feasible that approach is...

Reviewed-by: Stefan Hajnoczi <stefa...@redhat.com>

Reply via email to