From e235cec3762d2aa20b548114ea7b172113690463 Mon Sep 17 00:00:00 2001 From: Luiz Capitulino Date: Wed, 21 Sep 2011 15:29:55 -0300 Subject: qapi: Convert query-mice Signed-off-by: Anthony Liguori Signed-off-by: Luiz Capitulino --- qmp-commands.hx | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'qmp-commands.hx') diff --git a/qmp-commands.hx b/qmp-commands.hx index 4328e8b86c..c5355601cc 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -1663,6 +1663,12 @@ Example: EQMP + { + .name = "query-mice", + .args_type = "", + .mhandler.cmd_new = qmp_marshal_input_query_mice, + }, + SQMP query-vnc --------- -- cgit v1.2.1 From 791e7c820e969a69aa2568fb528dbe9f7e923f5a Mon Sep 17 00:00:00 2001 From: Luiz Capitulino Date: Tue, 13 Sep 2011 17:37:16 -0300 Subject: qapi: Convert query-migrate Signed-off-by: Anthony Liguori Signed-off-by: Luiz Capitulino --- qmp-commands.hx | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'qmp-commands.hx') diff --git a/qmp-commands.hx b/qmp-commands.hx index c5355601cc..8efdb25d0a 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -1919,6 +1919,12 @@ Examples: EQMP + { + .name = "query-migrate", + .args_type = "", + .mhandler.cmd_new = qmp_marshal_input_query_migrate, + }, + SQMP query-balloon ------------- -- cgit v1.2.1 From 755f196898e75bf453957609d1dbe02f73e5b12a Mon Sep 17 00:00:00 2001 From: Luiz Capitulino Date: Thu, 6 Oct 2011 14:31:39 -0300 Subject: qapi: Convert the cpu command Signed-off-by: Anthony Liguori Signed-off-by: Luiz Capitulino --- qmp-commands.hx | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'qmp-commands.hx') diff --git a/qmp-commands.hx b/qmp-commands.hx index 8efdb25d0a..dcca53cb5a 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -331,10 +331,7 @@ EQMP { .name = "cpu", .args_type = "index:i", - .params = "index", - .help = "set the default CPU", - .user_print = monitor_user_noop, - .mhandler.cmd_new = do_cpu_set, + .mhandler.cmd_new = qmp_marshal_input_cpu, }, SQMP -- cgit v1.2.1 From de0b36b67ea3e1ab3aa1b6625c4fd5cb29fa0ada Mon Sep 17 00:00:00 2001 From: Luiz Capitulino Date: Wed, 21 Sep 2011 16:38:35 -0300 Subject: qapi: Convert query-cpus Signed-off-by: Anthony Liguori Signed-off-by: Luiz Capitulino --- qmp-commands.hx | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'qmp-commands.hx') diff --git a/qmp-commands.hx b/qmp-commands.hx index dcca53cb5a..434ce6cba6 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -1347,6 +1347,12 @@ Example: EQMP + { + .name = "query-cpus", + .args_type = "", + .mhandler.cmd_new = qmp_marshal_input_query_cpus, + }, + SQMP query-pci --------- -- cgit v1.2.1 From b202381800d81fbff9978abbdea95760dd363bb6 Mon Sep 17 00:00:00 2001 From: Luiz Capitulino Date: Wed, 21 Sep 2011 17:16:47 -0300 Subject: qapi: Convert query-block Signed-off-by: Anthony Liguori Signed-off-by: Luiz Capitulino --- qmp-commands.hx | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'qmp-commands.hx') diff --git a/qmp-commands.hx b/qmp-commands.hx index 434ce6cba6..0cf0be7e0d 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -1198,6 +1198,12 @@ Example: EQMP + { + .name = "query-block", + .args_type = "", + .mhandler.cmd_new = qmp_marshal_input_query_block, + }, + SQMP query-blockstats ---------------- -- cgit v1.2.1 From f11f57e405a99732ed0f3294904c2dd258d77629 Mon Sep 17 00:00:00 2001 From: Luiz Capitulino Date: Thu, 22 Sep 2011 15:56:36 -0300 Subject: qapi: Convert query-blockstats Signed-off-by: Anthony Liguori Signed-off-by: Luiz Capitulino --- qmp-commands.hx | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'qmp-commands.hx') diff --git a/qmp-commands.hx b/qmp-commands.hx index 0cf0be7e0d..a250a7ada7 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -1311,6 +1311,12 @@ Example: EQMP + { + .name = "query-blockstats", + .args_type = "", + .mhandler.cmd_new = qmp_marshal_input_query_blockstats, + }, + SQMP query-cpus ---------- -- cgit v1.2.1 From 2b54aa879ea8490e25107dfc51a6ee268c84c273 Mon Sep 17 00:00:00 2001 From: Luiz Capitulino Date: Mon, 17 Oct 2011 16:41:22 -0200 Subject: qapi: Convert query-vnc There are three important remarks in relation to the non-qapi command: 1. This commit also fixes the behavior of the 'query-vnc' and 'info vnc' commands to return an error when qemu is built without VNC support (ie. --disable-vnc). The non-qapi command would return the OK response in QMP and no response in HMP 2. The qapi version explicitly marks the fields 'host', 'family', 'service' and 'auth' as optional. Their are not documented as optional in the non-qapi command doc, but they would not be returned if vnc support is disabled. The qapi version maintains the same semantics, but documents those fields correctly 3. The 'clients' field, which is a list, is marked as optional but is always returned. If there are no clients connected an empty list is returned. This is not the Right Way to this in the qapi but it's how the non-qapi command used to work Signed-off-by: Anthony Liguori Signed-off-by: Luiz Capitulino --- qmp-commands.hx | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'qmp-commands.hx') diff --git a/qmp-commands.hx b/qmp-commands.hx index a250a7ada7..0953d3f6be 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -1741,6 +1741,12 @@ Example: EQMP + { + .name = "query-vnc", + .args_type = "", + .mhandler.cmd_new = qmp_marshal_input_query_vnc, + }, + SQMP query-spice ----------- -- cgit v1.2.1 From d1f29646f21321e60d1be4e72ac3b6caaa0239cc Mon Sep 17 00:00:00 2001 From: Luiz Capitulino Date: Thu, 20 Oct 2011 17:01:33 -0200 Subject: qapi: Convert query-spice Signed-off-by: Anthony Liguori Signed-off-by: Luiz Capitulino --- qmp-commands.hx | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'qmp-commands.hx') diff --git a/qmp-commands.hx b/qmp-commands.hx index 0953d3f6be..e99c240f1a 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -1817,6 +1817,14 @@ Example: EQMP +#if defined(CONFIG_SPICE) + { + .name = "query-spice", + .args_type = "", + .mhandler.cmd_new = qmp_marshal_input_query_spice, + }, +#endif + SQMP query-name ---------- -- cgit v1.2.1 From 96637bcdf9e00db77265229d3d30d952bdde74be Mon Sep 17 00:00:00 2001 From: Luiz Capitulino Date: Fri, 21 Oct 2011 11:41:37 -0200 Subject: qapi: Convert query-balloon Please, note that some of the code supporting memory statistics is still around (eg. virtio_balloon_receive_stats() and reset_stats()). Also, the qmp_query_balloon() function is synchronous and thus doesn't make any use of the (not fully working) monitor's asynchronous command support (the old non-qapi implementation did). Signed-off-by: Anthony Liguori Signed-off-by: Luiz Capitulino --- qmp-commands.hx | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'qmp-commands.hx') diff --git a/qmp-commands.hx b/qmp-commands.hx index e99c240f1a..8ef6ca276a 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -1989,3 +1989,8 @@ Example: EQMP + { + .name = "query-balloon", + .args_type = "", + .mhandler.cmd_new = qmp_marshal_input_query_balloon, + }, -- cgit v1.2.1 From 79627472db3629de66fe81019560aa9cb6900268 Mon Sep 17 00:00:00 2001 From: Luiz Capitulino Date: Fri, 21 Oct 2011 14:15:33 -0200 Subject: qapi: Convert query-pci This also fixes a bug with the old version: QMP would invert device id and vendor id. This would look ok on HMP because it was printing "device:vendor" instead of "vendor:device". Signed-off-by: Anthony Liguori Signed-off-by: Luiz Capitulino --- qmp-commands.hx | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'qmp-commands.hx') diff --git a/qmp-commands.hx b/qmp-commands.hx index 8ef6ca276a..eb3072c504 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -1576,6 +1576,12 @@ Note: This example has been shortened as the real response is too long. EQMP + { + .name = "query-pci", + .args_type = "", + .mhandler.cmd_new = qmp_marshal_input_query_pci, + }, + SQMP query-kvm --------- -- cgit v1.2.1