Blob Blame History Raw
From b6ec816cb5032ff419a4c30f1a65ffb51250d52d Mon Sep 17 00:00:00 2001
From: Orit Wasserman <owasserm@redhat.com>
Date: Wed, 9 Oct 2013 10:09:13 +0200
Subject: [PATCH 18/25] migration: send total time in QMP at "completed" stage

RH-Author: Orit Wasserman <owasserm@redhat.com>
Message-id: <1381313355-15641-9-git-send-email-owasserm@redhat.com>
Patchwork-id: 54804
O-Subject: [RHEL7.0 qemu-kvm v2 08/10] migration: send total time in QMP at "completed" stage
Bugzilla: 921465
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
RH-Acked-by: Stefan Hajnoczi <stefanha@redhat.com>
RH-Acked-by: Juan Quintela <quintela@redhat.com>

From: Pawit Pornkitprasan <p.pawit@gmail.com>

The "completed" stage sets total_time but not has_total_time and
thus it is not sent via QMP reply (but sent via HMP nevertheless)

Signed-off-by: Pawit Pornkitprasan <p.pawit@gmail.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Orit Wasserman <owasserm@redhat.com>
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
(cherry picked from commit 00c14997cb95bf3e6c18c2264ef5e10642d89b3a)
---
 migration.c | 1 +
 1 file changed, 1 insertion(+)

Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
---
 migration.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/migration.c b/migration.c
index cc0e649..d69ac97 100644
--- a/migration.c
+++ b/migration.c
@@ -217,6 +217,7 @@ MigrationInfo *qmp_query_migrate(Error **errp)
 
         info->has_status = true;
         info->status = g_strdup("completed");
+        info->has_total_time = true;
         info->total_time = s->total_time;
         info->has_downtime = true;
         info->downtime = s->downtime;
-- 
1.7.1