From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49831) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZxgF3-0000NW-Lk for qemu-devel@nongnu.org; Sat, 14 Nov 2015 14:12:06 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZxgEz-0006my-H5 for qemu-devel@nongnu.org; Sat, 14 Nov 2015 14:12:05 -0500 Received: from v220110690675601.yourvserver.net ([37.221.199.173]:46409) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZxgEz-0006mi-BP for qemu-devel@nongnu.org; Sat, 14 Nov 2015 14:12:01 -0500 Message-ID: <5647877D.6050201@weilnetz.de> Date: Sat, 14 Nov 2015 20:11:57 +0100 From: Stefan Weil MIME-Version: 1.0 References: <1447165546-27784-1-git-send-email-quintela@redhat.com> <1447165546-27784-26-git-send-email-quintela@redhat.com> In-Reply-To: <1447165546-27784-26-git-send-email-quintela@redhat.com> Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PULL 25/57] Add wrappers and handlers for sending/receiving the postcopy-ram migration messages. List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Juan Quintela , qemu-devel@nongnu.org Cc: amit.shah@redhat.com, Paolo Bonzini , dgilbert@redhat.com Am 10.11.2015 um 15:25 schrieb Juan Quintela: > From: "Dr. David Alan Gilbert" > > The state of the postcopy process is managed via a series of messages; > * Add wrappers and handlers for sending/receiving these messages > * Add state variable that track the current state of postcopy > > Signed-off-by: Dr. David Alan Gilbert > Reviewed-by: Amit Shah > Reviewed-by: Juan Quintela > Signed-off-by: Juan Quintela > --- > include/migration/migration.h | 27 +++++ > include/sysemu/sysemu.h | 19 ++++ > migration/migration.c | 20 ++++ > migration/savevm.c | 254 ++++++++++++++++++++++++++++++++++= ++++++++ > trace-events | 10 ++ > 5 files changed, 330 insertions(+) > [...] > diff --git a/migration/savevm.c b/migration/savevm.c [...] > + if (remote_hps !=3D getpagesize()) { > + /* > + * Some combinations of mismatch are probably possible but it = gets > + * a bit more complicated. In particular we need to place who= le > + * host pages on the dest at once, and we need to ensure that = we > + * handle dirtying to make sure we never end up sending part o= f > + * a hostpage on it's own. > + */ > + error_report("Postcopy needs matching host page sizes (s=3D%d = d=3D%d)", > + (int)remote_hps, getpagesize()); This statement introduces a new warning when compiling for Windows where getpagesize() returns a size_t. I'll send a patch to change that definition to return an int value. Is there a special reason why a type cast was used here instead of using PRIu64? See also the format string below. Regards Stefan > + return -1; > + } > + > + remote_tps =3D qemu_get_be64(mis->from_src_file); > + if (remote_tps !=3D (1ul << qemu_target_page_bits())) { > + /* > + * Again, some differences could be dealt with, but for now ke= ep it > + * simple. > + */ > + error_report("Postcopy needs matching target page sizes (s=3D%= d d=3D%d)", > + (int)remote_tps, 1 << qemu_target_page_bits()); >