Deprecate HMP cpu-add

Since we're deprecating the QMP `cpu-add`, let's deprecate its HMP
equivalent, too.

Suggested-by: Thomas Huth <thuth@redhat.com>
Signed-off-by: Kashyap Chamarthy <kchamart@redhat.com>
Message-Id: <20181030123526.26415-3-kchamart@redhat.com>
Reviewed-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
This commit is contained in:
Kashyap Chamarthy 2018-10-30 13:35:25 +01:00 committed by Eduardo Habkost
parent 3800db787f
commit e25701b730
2 changed files with 6 additions and 2 deletions

2
hmp.c
View file

@ -2372,6 +2372,8 @@ void hmp_cpu_add(Monitor *mon, const QDict *qdict)
int cpuid;
Error *err = NULL;
error_report("cpu_add is deprecated, please use device_add instead");
cpuid = qdict_get_int(qdict, "id");
qmp_cpu_add(cpuid, &err);
hmp_handle_error(mon, &err);