Received: from eggs.gnu.org ([2001:4830:134:3::10]:55303) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XH9Zx-0007Kv-R2 for qemu-devel@nongnu.org; Tue, 12 Aug 2014 06:45:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XH9Zs-00073w-Nj for qemu-devel@nongnu.org; Tue, 12 Aug 2014 06:45:21 -0400 Received: from mx1.redhat.com ([209.132.183.28]:10801) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XH9Zs-00073q-Gr for qemu-devel@nongnu.org; Tue, 12 Aug 2014 06:45:16 -0400 Date: Tue, 12 Aug 2014 11:45:11 +0100 From: Stefan Hajnoczi Message-ID: <20140812104511.GI20490@stefanha-thinkpad.redhat.com> References: <1407172228-11690-1-git-send-email-milos.vyletel@gmail.com> <1407360282-10036-1-git-send-email-milos.vyletel@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="81JctsDUVPekGcy+" Content-Disposition: inline In-Reply-To: <1407360282-10036-1-git-send-email-milos.vyletel@gmail.com> Subject: Re: [Qemu-devel] [PATCH v3] vmdk: improve streamOptimized vmdk support List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Milos Vyletel Cc: Kevin Wolf , Fam Zheng , qemu-devel@nongnu.org --81JctsDUVPekGcy+ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Aug 06, 2014 at 05:24:42PM -0400, Milos Vyletel wrote: > VMDK's streamOptimized format is different from regular sparse format. > L1(GD) and L2(GT) tables are not predefined but rather generated and > written during image creation mainly because there is no way to tell > how much space data will occupy once they are compressed. Also the > location of header, L1 and L2 tables differ. >=20 > - L2 tables (grain tables) are written after all grains they point to > - L1 tables are written after all grains and L2 tables > - footer at the end is used instead of header in first sector >=20 > Images generated by qemu-img could not be imported (as part of OVA archiv= e) > to neither VMWare nor OVM because of errors. >=20 > - VMWare during OVA import: > Not a supported disk format (sparse VMDK too old) >=20 > - OVM's vbox-img during conversion: > vbox-img: error: Error while copying the image: VERR_EOF >=20 > This patch fixes streamOptimized support in qemu which was not fully > compatible with VMDK specifications as defined in latest avaialble version > at https://www.vmware.com/support/developer/vddk/vmdk_50_technote.pdf. >=20 > Qemu generated images are identical to the ones generated by VMWare and > OVM (vbox-img) with the exception of DescriptorFile but that is expected > (CID and some additional DDB entries differ). They were also succesfully > imported to VMWare vCloud, ESXi and Oracle OVM. >=20 > Signed-off-by: Milos Vyletel > --- > v2 changes: > - updated commit message description with errors received > - style/grammar fixes (clean checkpatch pass) > - removed l2_table pointer from VmdkExtent struct > - fixed memory leak in vmdk_write_footer() >=20 > v3 changes: > - removed footer from VmdkExtent structure > - added vmdk_write_grain_directory function to separate GD and footer wri= tes > - fix possible problems with opening of images created by older implement= ation > - fix reverse conversion from VMDK to other formats >=20 > block/vmdk.c | 355 +++++++++++++++++++++++++++++++++++++++++++++-------= ----- > 1 files changed, 280 insertions(+), 75 deletions(-) In the future, please send revisions as top-level email threads. When people use threaded email clients your patch can be overlooked since it's a subthread of an old discussion, rather than a new thread in the inbox. I skimmed the patch and am relying on Fam for a detailed review. --81JctsDUVPekGcy+ Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAEBAgAGBQJT6fA3AAoJEJykq7OBq3PIqmoH/0l4VJZrLgVFA0uV2A4si+Mx JFuBmlIWmTJiRXeIjq+HjFJuAoigZk1FcJcBnn0GMVt5EO0/MwrKI0as0HHPtja0 muUrYs9PKZVLcebaoRmROhp4pMES+rDan/RlUEcvOEvmbYlMzujTB2ZanAPkS81v qSuDf8FOiWbly+POWjIboP418ZRzT0+x0rgzqpIfzPVYSzoDlLt150v3/LkNEsZ/ OoDdZ/fAb5eeTBA0eYjdk4tMq2zuKScger+Vonch+nHX59xMM4QwDiEf+8TBQo3k PzifmEzN91jlfvtN9OBDdEzpZJvsEmF1kYRsjDGr8AU4sH0X6PmGE3YNBZmAnG8= =vFRl -----END PGP SIGNATURE----- --81JctsDUVPekGcy+--