aboutsummaryrefslogtreecommitdiff
path: root/hmp.c
diff options
context:
space:
mode:
authorDr. David Alan Gilbert <dgilbert@redhat.com>2019-02-27 13:24:06 +0000
committerJason Wang <jasowang@redhat.com>2019-03-05 11:27:41 +0800
commitee3d96baf32350dd273643bd220bc180c62923cf (patch)
tree31ca3a4f9341a16b4f5b21d57ba115be4407c4b4 /hmp.c
parent50510ea2c2960cc48e9cc1676dde88b849933b6e (diff)
migration: Add announce parameters
Add migration parameters that control RARP/GARP announcement timeouts. Based on earlier patches by myself and Vladislav Yasevich <vyasevic@redhat.com> Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Acked-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Jason Wang <jasowang@redhat.com>
Diffstat (limited to 'hmp.c')
-rw-r--r--hmp.c28
1 files changed, 28 insertions, 0 deletions
diff --git a/hmp.c b/hmp.c
index 1e006eeb49..f3db0bf5a2 100644
--- a/hmp.c
+++ b/hmp.c
@@ -334,6 +334,18 @@ void hmp_info_migrate_parameters(Monitor *mon, const QDict *qdict)
params = qmp_query_migrate_parameters(NULL);
if (params) {
+ monitor_printf(mon, "%s: %" PRIu64 " ms\n",
+ MigrationParameter_str(MIGRATION_PARAMETER_ANNOUNCE_INITIAL),
+ params->announce_initial);
+ monitor_printf(mon, "%s: %" PRIu64 " ms\n",
+ MigrationParameter_str(MIGRATION_PARAMETER_ANNOUNCE_MAX),
+ params->announce_max);
+ monitor_printf(mon, "%s: %" PRIu64 "\n",
+ MigrationParameter_str(MIGRATION_PARAMETER_ANNOUNCE_ROUNDS),
+ params->announce_rounds);
+ monitor_printf(mon, "%s: %" PRIu64 " ms\n",
+ MigrationParameter_str(MIGRATION_PARAMETER_ANNOUNCE_STEP),
+ params->announce_step);
assert(params->has_compress_level);
monitor_printf(mon, "%s: %u\n",
MigrationParameter_str(MIGRATION_PARAMETER_COMPRESS_LEVEL),
@@ -1757,6 +1769,22 @@ void hmp_migrate_set_parameter(Monitor *mon, const QDict *qdict)
p->has_max_postcopy_bandwidth = true;
visit_type_size(v, param, &p->max_postcopy_bandwidth, &err);
break;
+ case MIGRATION_PARAMETER_ANNOUNCE_INITIAL:
+ p->has_announce_initial = true;
+ visit_type_size(v, param, &p->announce_initial, &err);
+ break;
+ case MIGRATION_PARAMETER_ANNOUNCE_MAX:
+ p->has_announce_max = true;
+ visit_type_size(v, param, &p->announce_max, &err);
+ break;
+ case MIGRATION_PARAMETER_ANNOUNCE_ROUNDS:
+ p->has_announce_rounds = true;
+ visit_type_size(v, param, &p->announce_rounds, &err);
+ break;
+ case MIGRATION_PARAMETER_ANNOUNCE_STEP:
+ p->has_announce_step = true;
+ visit_type_size(v, param, &p->announce_step, &err);
+ break;
default:
assert(0);
}