aboutsummaryrefslogtreecommitdiff
path: root/hmp.c
diff options
context:
space:
mode:
authorLuiz Capitulino <lcapitulino@redhat.com>2011-09-14 16:05:49 -0300
committerLuiz Capitulino <lcapitulino@redhat.com>2011-10-04 11:02:57 -0300
commitc5a415a0afddbc217263b62a8e87d8ec9e7f760f (patch)
tree5be30ea3266b82c1e4ea4c1e2fd24ad66d11b90c /hmp.c
parentefab767eaafe39a234e8244819d0969ff59a325a (diff)
qapi: Convert query-chardev
Reviewed-by: Michael Roth <mdroth@linux.vnet.ibm.com> Tested-by: Michael Roth <mdroth@linux.vnet.ibm.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Diffstat (limited to 'hmp.c')
-rw-r--r--hmp.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/hmp.c b/hmp.c
index 25302f571d..30c6cc9511 100644
--- a/hmp.c
+++ b/hmp.c
@@ -80,3 +80,16 @@ void hmp_info_uuid(Monitor *mon)
monitor_printf(mon, "%s\n", info->UUID);
qapi_free_UuidInfo(info);
}
+
+void hmp_info_chardev(Monitor *mon)
+{
+ ChardevInfoList *char_info, *info;
+
+ char_info = qmp_query_chardev(NULL);
+ for (info = char_info; info; info = info->next) {
+ monitor_printf(mon, "%s: filename=%s\n", info->value->label,
+ info->value->filename);
+ }
+
+ qapi_free_ChardevInfoList(char_info);
+}