Received: from eggs.gnu.org ([2001:4830:134:3::10]:37504) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UrrHk-0002wZ-2B for qemu-devel@nongnu.org; Wed, 26 Jun 2013 11:05:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UrrHi-0001dN-Sz for qemu-devel@nongnu.org; Wed, 26 Jun 2013 11:05:27 -0400 Received: from mx1.redhat.com ([209.132.183.28]:14574) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UrrHi-0001dE-Lk for qemu-devel@nongnu.org; Wed, 26 Jun 2013 11:05:26 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r5QF5P6J032449 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 26 Jun 2013 11:05:25 -0400 Date: Wed, 26 Jun 2013 17:05:23 +0200 From: Kevin Wolf Message-ID: <20130626150523.GE2720@dhcp-200-207.str.redhat.com> References: <1372238672-2614-1-git-send-email-famz@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1372238672-2614-1-git-send-email-famz@redhat.com> Subject: Re: [Qemu-devel] [PATCH] vmdk: remove wrong calculation of relative path List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Fam Zheng Cc: qemu-devel@nongnu.org, stefanha@redhat.com Am 26.06.2013 um 11:24 hat Fam Zheng geschrieben: > When creating image with backing file, the driver tries to calculate the > relative path from created image file to backing file, but the path > computation is incorrect. e.g.: > > $ qemu-img create -f vmdk -b vmdk-data-disk.vmdk vmdk-data-snapshot1 > Formatting 'vmdk-data-snapshot1', fmt=vmdk size=10737418240 > backing_file='vmdk-data-disk.vmdk' compat6=off zeroed_grain=off > > $ qemu-img info vmdk-data-snapshot1 > image: vmdk-data-snapshot1 > file format: vmdk > virtual size: 10G (10737418240 bytes) > disk size: 12K > -> backing file: disk.vmdk > > The common part in file names, "vmdk-data-", is incorrectly forgotten by > relative_path(). As the VMDK specification has no restriction on > parentNameHint to be relative path, we simply remove this by using the > backing_file option. > > Signed-off-by: Fam Zheng Nice one. Thanks, applied to the block branch. Kevin