]> git.proxmox.com Git - qemu.git/commitdiff
Revert "qdev: Add help for device properties"
authorMarkus Armbruster <armbru@redhat.com>
Fri, 29 Jan 2010 18:48:59 +0000 (19:48 +0100)
committerAnthony Liguori <aliguori@us.ibm.com>
Wed, 3 Feb 2010 18:39:01 +0000 (12:39 -0600)
This reverts commit 2ba6edf0dd740166632df80caa85992b20791a68.

The commit has two issues:

* When it runs from the monitor, e.g. "device_add e1000,?", it prints
  to stderr instead of the monitor.

* Help looks to callers just like failed device creation.  This makes
  main() exit unsuccessfully on "-device e1000,?".

We need to do this differently.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
hw/qdev-properties.c

index 8547ad27d492c8e1bb77fbf5319fb6f559f2011b..277ff9e78092f6ebefe7786394b54054934f1177 100644 (file)
@@ -544,19 +544,8 @@ int qdev_prop_parse(DeviceState *dev, const char *name, const char *value)
 
     prop = qdev_prop_find(dev, name);
     if (!prop) {
-        if (strcmp(name, "?") != 0) {
-            fprintf(stderr, "property \"%s.%s\" not found\n",
-                    dev->info->name, name);
-        } else {
-            fprintf(stderr, "supported properties:\n");
-            if (dev->info->props != NULL) {
-                Property *props = dev->info->props;
-                while (props->name) {
-                    fprintf(stderr, "%s.%s\n", dev->info->name, props->name);
-                    props++;
-                }
-            }
-        }
+        fprintf(stderr, "property \"%s.%s\" not found\n",
+                dev->info->name, name);
         return -1;
     }
     if (!prop->info->parse) {