From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40928) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xz5LA-0001XM-KU for qemu-devel@nongnu.org; Thu, 11 Dec 2014 10:07:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xz5L4-0002vE-Rw for qemu-devel@nongnu.org; Thu, 11 Dec 2014 10:07:40 -0500 Received: from mx1.redhat.com ([209.132.183.28]:33722) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xz5L4-0002up-Jg for qemu-devel@nongnu.org; Thu, 11 Dec 2014 10:07:34 -0500 Message-ID: <5489B333.8060502@redhat.com> Date: Thu, 11 Dec 2014 08:07:31 -0700 From: Eric Blake MIME-Version: 1.0 References: <1418298924-4173-1-git-send-email-vsementsov@parallels.com> <1418298924-4173-2-git-send-email-vsementsov@parallels.com> In-Reply-To: <1418298924-4173-2-git-send-email-vsementsov@parallels.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="JjdImcc5s3kRG9wkIqk0HhpuDddmuvF14" Subject: Re: [Qemu-devel] [PATCH] block-migration: fix pending() return value List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Vladimir Sementsov-Ogievskiy , qemu-devel@nongnu.org Cc: kwolf@redhat.com, den@openvz.org, stefanha@redhat.com This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --JjdImcc5s3kRG9wkIqk0HhpuDddmuvF14 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 12/11/2014 04:55 AM, Vladimir Sementsov-Ogievskiy wrote: > Because of wrong return value of .save_live_pending() in > block-migration, migration finishes before the whole disk > is transferred. Such situation occures when the migration s/occures/occurs/ > process is fast enouth, for example when source and dest s/enouth/enough/ > are on the same host. >=20 > If in the bulk phase we return something < max_size, we will skip > transferring the tail of the device. Currently we have "set pending to > BLOCK_SIZE if it is zero" for bulk phase, but there no guarantee, that > it will be < max_size. >=20 > True approach is to return, for example, max_size+1 when we are in the > bulk phase. >=20 > Signed-off-by: Vladimir Sementsov-Ogievskiy > --- > block-migration.c | 4 ++-- I'll let someone else review the code proper. --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --JjdImcc5s3kRG9wkIqk0HhpuDddmuvF14 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg iQEcBAEBCAAGBQJUibMzAAoJEKeha0olJ0Nq7fMH/3YNXjTA43LQ5G6LkEWa0qgg 5BebMUN+g2KClNCfob9EBaNsLTpjRYwLBDSGLgbAXtmMnBDMtHHrNtvqFgp8sMRv tZ0o61bp0ksAgB80NqlpID8z7844nijAruIzPBiwxjXGyPzecfcC5OVfwafQ4PZB Wfb+/WgUVyJmH8/CM519/kmmhN+jGrAD0vYvQ4uUyW/vPjcXhOzDuH+cQfi3zI01 dKXYpewBVju8RZJiZ0YAME2iu01oct4Dm5lYAvRgn6OflCW0oRlMrVpiiiadiHnr 6EgEiuUfANwUl4MPFYRmaOTnZjsewg1bgwZL7r7h3At57a+9stGDvEZ+oEMxxEE= =fWf4 -----END PGP SIGNATURE----- --JjdImcc5s3kRG9wkIqk0HhpuDddmuvF14--