From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46330) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uorwo-000861-G6 for qemu-devel@nongnu.org; Tue, 18 Jun 2013 05:11:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Uorwn-0003H4-B2 for qemu-devel@nongnu.org; Tue, 18 Jun 2013 05:11:30 -0400 Received: from mx1.redhat.com ([209.132.183.28]:2472) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uorwn-0003Gv-3W for qemu-devel@nongnu.org; Tue, 18 Jun 2013 05:11:29 -0400 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r5I9BRhV004939 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 18 Jun 2013 05:11:27 -0400 Message-ID: <51C02439.10805@redhat.com> Date: Tue, 18 Jun 2013 11:11:21 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: <20130617093241.GA22609@localhost.nay.redhat.com> <51BEDCB9.5090905@redhat.com> <20130617135253.GB3994@dhcp-200-207.str.redhat.com> <51BF16B8.6040801@redhat.com> <20130617142605.GD3994@dhcp-200-207.str.redhat.com> <51BF213F.60601@redhat.com> <20130617151238.GF3994@dhcp-200-207.str.redhat.com> <20130618035854.GA17533@localhost.nay.redhat.com> <871u7zx6u3.fsf@blackfin.pond.sub.org> <51C01CEF.4070907@redhat.com> <20130618085620.GE3640@dhcp-200-207.str.redhat.com> In-Reply-To: <20130618085620.GE3640@dhcp-200-207.str.redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] block: add 'backing' option to drive_add List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf Cc: Markus Armbruster , stefanha@redhat.com, qemu-devel@nongnu.org Il 18/06/2013 10:56, Kevin Wolf ha scritto: >> > >> > It is a huge swamp indeed. >> > >> > Since we stop all block jobs on media change already, what about just >> > adding a command "block-job-attach" or something like that which exposes >> > the target of the job as a blockdev (presumably so that you can then add >> > it to the NBD server)? > This is backwards. You should really give the block job a target BDS to > begin with, not a file name. That's also ok... We can get the backing file right for the target BDS at the beginning of the backup job with a combination of close_unused_images (so that it is "as if" block-backup had opened the file with BDRV_O_NO_BACKING), bdrv_append and bdrv_swap (append the target to the VM's BDS, swap the two). So why do we need this new option to drive_add? The "drive" ImageCreationMode, for which Fam has a patch too, should do. Paolo