From: Gerd Hoffmann Date: Fri, 16 Sep 2011 09:25:05 +0000 (+0200) Subject: qdev: print bus properties too X-Git-Tag: cpu-hotplug-port-v2~2297 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=a8467c7a0e8b024a18608ff7db31ca2f2297e641;p=people%2Faperard%2Fqemu-dm.git qdev: print bus properties too Make qdev_device_help print both device and bus properties. Helps libvirt to figure whenever bus properties such as PCI.multifunction are supported present or not. Signed-off-by: Gerd Hoffmann Signed-off-by: Anthony Liguori --- diff --git a/hw/qdev.c b/hw/qdev.c index c463c52150..a223d41cd3 100644 --- a/hw/qdev.c +++ b/hw/qdev.c @@ -207,6 +207,12 @@ int qdev_device_help(QemuOpts *opts) } error_printf("%s.%s=%s\n", info->name, prop->name, prop->info->name); } + for (prop = info->bus_info->props; prop && prop->name; prop++) { + if (!prop->info->parse) { + continue; /* no way to set it, don't show */ + } + error_printf("%s.%s=%s\n", info->name, prop->name, prop->info->name); + } return 1; }