From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37056) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ceKZP-0006d2-VD for qemu-devel@nongnu.org; Thu, 16 Feb 2017 06:49:57 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ceKZO-0006T1-C4 for qemu-devel@nongnu.org; Thu, 16 Feb 2017 06:49:55 -0500 Date: Thu, 16 Feb 2017 12:49:44 +0100 From: Kevin Wolf Message-ID: <20170216114944.GD4869@noname.redhat.com> References: <1487153430-17260-1-git-send-email-vsementsov@virtuozzo.com> <1487153430-17260-9-git-send-email-vsementsov@virtuozzo.com> <20170216112506.GB4869@noname.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170216112506.GB4869@noname.redhat.com> Subject: Re: [Qemu-devel] [PATCH v15 08/25] block: introduce auto-loading bitmaps List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Vladimir Sementsov-Ogievskiy Cc: qemu-block@nongnu.org, qemu-devel@nongnu.org, mreitz@redhat.com, armbru@redhat.com, eblake@redhat.com, jsnow@redhat.com, famz@redhat.com, den@openvz.org, stefanha@redhat.com, pbonzini@redhat.com Am 16.02.2017 um 12:25 hat Kevin Wolf geschrieben: > Am 15.02.2017 um 11:10 hat Vladimir Sementsov-Ogievskiy geschrieben: > > Auto loading bitmaps are bitmaps stored in the disk image, which should > > be loaded when the image is opened and become BdrvDirtyBitmaps for the > > corresponding drive. > > > > Signed-off-by: Vladimir Sementsov-Ogievskiy > > Reviewed-by: John Snow > > Reviewed-by: Max Reitz > > Why do we need a new BlockDriver callback and special code for it in > bdrv_open_common()? The callback is only ever called immediately after > .bdrv_open/.bdrv_file_open, so can't the drivers just do this internally > in their .bdrv_open implementation? Even more so because qcow2 is the > only driver that supports this callback. Actually, don't we have to call this in qcow2_invalidate_cache()? Currently, I think, after a migration, the autoload bitmaps aren't loaded. By moving the qcow2_load_autoloading_dirty_bitmaps() call to qcow2_open(), this would be fixed. Kevin