aboutsummaryrefslogtreecommitdiff
path: root/monitor.c
diff options
context:
space:
mode:
authorLuiz Capitulino <lcapitulino@redhat.com>2011-09-13 17:16:25 -0300
committerLuiz Capitulino <lcapitulino@redhat.com>2011-10-04 11:02:57 -0300
commitefab767eaafe39a234e8244819d0969ff59a325a (patch)
tree08406c2ce1553d34f7c5d60cf75b4cb55be2b343 /monitor.c
parent1fa9a5e4aea36b4d21e42323ae43879c908af576 (diff)
qapi: Convert query-uuid
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Diffstat (limited to 'monitor.c')
-rw-r--r--monitor.c28
1 files changed, 1 insertions, 27 deletions
diff --git a/monitor.c b/monitor.c
index e68f2e2722..4e9ecdfea3 100644
--- a/monitor.c
+++ b/monitor.c
@@ -766,23 +766,6 @@ static void do_info_commands(Monitor *mon, QObject **ret_data)
*ret_data = QOBJECT(cmd_list);
}
-static void do_info_uuid_print(Monitor *mon, const QObject *data)
-{
- monitor_printf(mon, "%s\n", qdict_get_str(qobject_to_qdict(data), "UUID"));
-}
-
-static void do_info_uuid(Monitor *mon, QObject **ret_data)
-{
- char uuid[64];
-
- snprintf(uuid, sizeof(uuid), UUID_FMT, qemu_uuid[0], qemu_uuid[1],
- qemu_uuid[2], qemu_uuid[3], qemu_uuid[4], qemu_uuid[5],
- qemu_uuid[6], qemu_uuid[7], qemu_uuid[8], qemu_uuid[9],
- qemu_uuid[10], qemu_uuid[11], qemu_uuid[12], qemu_uuid[13],
- qemu_uuid[14], qemu_uuid[15]);
- *ret_data = qobject_from_jsonf("{ 'UUID': %s }", uuid);
-}
-
/* get the current CPU defined by the user */
static int mon_set_cpu(int cpu_index)
{
@@ -2996,8 +2979,7 @@ static const mon_cmd_t info_cmds[] = {
.args_type = "",
.params = "",
.help = "show the current VM UUID",
- .user_print = do_info_uuid_print,
- .mhandler.info_new = do_info_uuid,
+ .mhandler.info = hmp_info_uuid,
},
#if defined(TARGET_PPC)
{
@@ -3157,14 +3139,6 @@ static const mon_cmd_t qmp_query_cmds[] = {
},
#endif
{
- .name = "uuid",
- .args_type = "",
- .params = "",
- .help = "show the current VM UUID",
- .user_print = do_info_uuid_print,
- .mhandler.info_new = do_info_uuid,
- },
- {
.name = "migrate",
.args_type = "",
.params = "",