diff options
author | Gerd Hoffmann <kraxel@redhat.com> | 2009-12-08 13:11:35 +0100 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2009-12-12 07:59:41 -0600 |
commit | 07a8de3566bd576dc33e55af830d63dcc2287617 (patch) | |
tree | 5ad085cedf8405ddc7b9411119fda0f3b39bf334 /hw/qdev-properties.c | |
parent | d0fef6fbea36c62d29f3e3fa2214b7b52322983e (diff) |
qdev: also match bus name for global properties
i.e. -global PCI.<property>=<value> will set a default property for all
PCI devices. Also works for the compat properties used by machine
types.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'hw/qdev-properties.c')
-rw-r--r-- | hw/qdev-properties.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/hw/qdev-properties.c b/hw/qdev-properties.c index fe106bd6a..fb07279ba 100644 --- a/hw/qdev-properties.c +++ b/hw/qdev-properties.c @@ -614,7 +614,8 @@ void qdev_prop_set_globals(DeviceState *dev) GlobalProperty *prop; QTAILQ_FOREACH(prop, &global_props, next) { - if (strcmp(dev->info->name, prop->driver) != 0) { + if (strcmp(dev->info->name, prop->driver) != 0 && + strcmp(dev->info->bus_info->name, prop->driver) != 0) { continue; } if (qdev_prop_parse(dev, prop->property, prop->value) != 0) { |