qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH v2] QMP: Introduce the documentation for query-qdm
@ 2010-07-09 18:13 Miguel Di Ciurcio Filho
  2010-07-09 21:47 ` [Qemu-devel] " Luiz Capitulino
  2010-07-13 11:49 ` [Qemu-devel] " Markus Armbruster
  0 siblings, 2 replies; 9+ messages in thread
From: Miguel Di Ciurcio Filho @ 2010-07-09 18:13 UTC (permalink / raw)
  To: qemu-devel; +Cc: armbru, lcapitulino, Miguel Di Ciurcio Filho, avi

Changelog from v1
-----------------
- renamed "props" to "properties"
- updated the examples
- reworded the explanations of "name" and "description"
- split "type" into a json-object, adding "qmp" and "qdev"
- list all possible values for "bus"
- list all possible values for "qdev" on "type"
- list all possible values for "qmp" on "type"
---
 qemu-monitor.hx |   88 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 88 insertions(+), 0 deletions(-)

diff --git a/qemu-monitor.hx b/qemu-monitor.hx
index 2af3de6..0055d0a 100644
--- a/qemu-monitor.hx
+++ b/qemu-monitor.hx
@@ -2490,6 +2490,94 @@ STEXI
 show device tree
 @item info qdm
 show qdev device model list
+ETEXI
+SQMP
+query-qdm
+---------
+
+Describe the capabilities of all devices registered with qdev.
+
+The returned output is a json-array, each element is a json-object describing
+a single device type.
+
+Each json-object contains the following:
+
+- "name": name of the device (json-string)
+- "bus": the name of the bus type for the device (json-string)
+    - Possible values: PCI, SCSI, I2C, ISA, SSI, USB, virtio-serial-bus, System
+- "alias": an alias by which the device is also known (json-string, optional)
+- "description": description of the device  (json-string, optional)
+- "creatable": whether this device can be created on command line (json-boolean)
+- "properties": a list where each element is an json-object that describes a
+  property of the device. Each json-object contains the following:
+     - "name": the name of the property (json-string)
+     - "type": a json-object that contains the following:
+        - "qdev": the internal name of the type of the property (json-string)
+            - Possible values: uint8, uint16, uint32, uint64, int32, macaddr,
+              drive, chr, string, netdev, bit, taddr
+        - "qmp": the json equivalent type of the internal type (json-string)
+            - Possible values: integer, string, boolean
+
+Example:
+
+-> { "execute": "query-qdm" }
+<- {
+      "return": [
+        {
+           "name": "virtio-blk-pci",
+           "creatable": true,
+           "bus": "PCI",
+           "properties": [
+             {
+                 "name": "indirect_desc",
+                 "type": {
+                             "qdev": "bit",
+                             "qmp": "boolean"
+                         }
+             },
+             {
+                 "name": "logical_block_size",
+                 "type": {
+                             "qdev": "uint16",
+                             "qmp": "integer"
+                         }
+             },
+             {
+                 "name": "opt_io_size",
+                 "type": {
+                             "qdev": "uint32",
+                             "qmp": "integer"
+                         }
+             }
+             {
+                 "name": "drive",
+                 "type": {
+                             "qdev": "drive",
+                             "qmp": "string"
+                         }
+             }
+           ]
+        },
+        {
+           "name": "virtio-balloon-pci",
+           "creatable": true,
+           "bus": "PCI",
+           "properties": [
+             {
+                 "name": "indirect_desc",
+                 "type": {
+                             "qdev": "bit",
+                             "qmp": "boolean"
+                         }
+             }
+           ]
+        },
+      ....
+    ]
+
+EQMP
+
+STEXI
 @item info roms
 show roms
 @end table
-- 
1.7.1

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2010-07-15  9:14 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-07-09 18:13 [Qemu-devel] [PATCH v2] QMP: Introduce the documentation for query-qdm Miguel Di Ciurcio Filho
2010-07-09 21:47 ` [Qemu-devel] " Luiz Capitulino
2010-07-13 11:49 ` [Qemu-devel] " Markus Armbruster
2010-07-13 13:30   ` Miguel Di Ciurcio Filho
2010-07-13 13:44     ` Luiz Capitulino
2010-07-13 13:42   ` Luiz Capitulino
2010-07-13 16:20     ` Markus Armbruster
2010-07-14 19:19       ` Luiz Capitulino
2010-07-15  9:12         ` Markus Armbruster

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).