From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60767) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bBwwC-0001Fe-FF for qemu-devel@nongnu.org; Sun, 12 Jun 2016 00:23:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bBwwA-0004Me-GF for qemu-devel@nongnu.org; Sun, 12 Jun 2016 00:23:51 -0400 Date: Sun, 12 Jun 2016 12:23:38 +0800 From: Fam Zheng Message-ID: <20160612042338.GI27167@ad.usersys.redhat.com> References: <20160610185750.30956-1-mreitz@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20160610185750.30956-1-mreitz@redhat.com> Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH v3 0/5] block/mirror: Fix (?) target backing BDS List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Max Reitz Cc: qemu-block@nongnu.org, qemu-devel@nongnu.org, Kevin Wolf On Fri, 06/10 20:57, Max Reitz wrote: > Issue #1: If the target image does not have a backing BDS before mirror > completion, qemu tries really hard to give it a backing BDS. If the > source has a backing BDS, it will actually always "succeed". > In some cases, the target is not supposed to have a backing BDS, though > (absolute-paths: because of sync=3Dfull; existing: because the target > image does not have a backing file; blockdev-mirror: because of an > explicit "backing": ""). Then, this is pretty bad behavior. >=20 > This should generally not change the target's visible data, but it stil= l > is ugly. >=20 > Issue #2: Currently the backing chain of the target is basically opened > using bdrv_open_backing_file() (except for sometimes=E2=84=A2). This re= sults in > multiple BDSs for a single physical file, which is bad. In most use > cases, this is only temporary, but it still is bad. >=20 > If we can reuse the existing backing chain of the source (which is with > drive-mirror in "absolute-paths" mode), we should just do so. Looks good overall. I left a few trivial comments/questions in individual patches. Reviewed-by: Fam Zheng