From patchwork Tue May 25 14:21:04 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Juan Quintela X-Patchwork-Id: 53554 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id E673FB6ED0 for ; Wed, 26 May 2010 00:34:52 +1000 (EST) Received: from localhost ([127.0.0.1]:54745 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OGvDV-0006xf-LU for incoming@patchwork.ozlabs.org; Tue, 25 May 2010 10:34:49 -0400 Received: from [140.186.70.92] (port=38666 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OGv0Q-0002uc-4A for qemu-devel@nongnu.org; Tue, 25 May 2010 10:21:19 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OGv0O-0002Lm-LS for qemu-devel@nongnu.org; Tue, 25 May 2010 10:21:17 -0400 Received: from mx1.redhat.com ([209.132.183.28]:14197) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OGv0O-0002Lb-Ec for qemu-devel@nongnu.org; Tue, 25 May 2010 10:21:16 -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.13.8/8.13.8) with ESMTP id o4PELF6x009196 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 25 May 2010 10:21:15 -0400 Received: from localhost.localdomain (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o4PEL6Cb020067; Tue, 25 May 2010 10:21:14 -0400 From: Juan Quintela To: qemu-devel@nongnu.org Date: Tue, 25 May 2010 16:21:04 +0200 Message-Id: In-Reply-To: References: In-Reply-To: References: X-Scanned-By: MIMEDefang 2.67 on 10.5.11.12 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. Subject: [Qemu-devel] [PATCH 4/5] QMP: Emit migration events on incoming migration X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Signed-off-by: Juan Quintela --- migration.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/migration.c b/migration.c index c388902..32470d5 100644 --- a/migration.c +++ b/migration.c @@ -60,10 +60,13 @@ int qemu_start_incoming_migration(const char *uri) void process_incoming_migration(QEMUFile *f) { + monitor_protocol_event(QEVENT_MIGRATION_STARTED, NULL); if (qemu_loadvm_state(f) < 0) { + monitor_protocol_event(QEVENT_MIGRATION_FAILED, NULL); fprintf(stderr, "load of migration failed\n"); exit(0); } + monitor_protocol_event(QEVENT_MIGRATION_ENDED, NULL); qemu_announce_self(); DPRINTF("successfully loaded vm state\n");