aboutsummaryrefslogtreecommitdiff
path: root/qmp-commands.hx
diff options
context:
space:
mode:
authorAnthony Liguori <aliguori@us.ibm.com>2011-12-22 14:40:54 -0600
committerAnthony Liguori <aliguori@us.ibm.com>2012-02-03 10:41:07 -0600
commit5eeee3fa2e646dadeea2c10515956b11ed0de877 (patch)
tree77a45e043e2afad81005d12009c24146b125319c /qmp-commands.hx
parent6acbe4c6f18e7de00481ff30574262b58526de45 (diff)
downloadqemu-5eeee3fa2e646dadeea2c10515956b11ed0de877.zip
qemu-5eeee3fa2e646dadeea2c10515956b11ed0de877.tar.gz
qemu-5eeee3fa2e646dadeea2c10515956b11ed0de877.tar.bz2
qom: add new command to search for types
This adds a command that allows searching for types that implement a property. This allows you to do things like search for all available PCIDevices. In the future, we'll also have a standard interface for things with a BlockDriverState property that a PCIDevice could implement. This will enable search queries like, "any type that implements the BlockDevice interface" which would allow management tools to present available block devices without having to hard code device names. Since an object can implement multiple interfaces, one device could act both as a BlockDevice and a NetworkDevice. Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'qmp-commands.hx')
-rw-r--r--qmp-commands.hx5
1 files changed, 5 insertions, 0 deletions
diff --git a/qmp-commands.hx b/qmp-commands.hx
index bd6b641..b5e2ab8 100644
--- a/qmp-commands.hx
+++ b/qmp-commands.hx
@@ -2042,3 +2042,8 @@ EQMP
.args_type = "password:s",
.mhandler.cmd_new = qmp_marshal_input_change_vnc_password,
},
+ {
+ .name = "qom-list-types",
+ .args_type = "implements:s?,abstract:b?",
+ .mhandler.cmd_new = qmp_marshal_input_qom_list_types,
+ },