aboutsummaryrefslogtreecommitdiff
path: root/hw/core/qdev-properties.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/core/qdev-properties.c')
-rw-r--r--hw/core/qdev-properties.c21
1 files changed, 9 insertions, 12 deletions
diff --git a/hw/core/qdev-properties.c b/hw/core/qdev-properties.c
index 2e47f70eb4..5a4e4d5ec8 100644
--- a/hw/core/qdev-properties.c
+++ b/hw/core/qdev-properties.c
@@ -990,8 +990,8 @@ int qdev_prop_check_globals(void)
return ret;
}
-void qdev_prop_set_globals_for_type(DeviceState *dev, const char *typename,
- Error **errp)
+static void qdev_prop_set_globals_for_type(DeviceState *dev,
+ const char *typename)
{
GlobalProperty *prop;
@@ -1004,25 +1004,22 @@ void qdev_prop_set_globals_for_type(DeviceState *dev, const char *typename,
prop->used = true;
object_property_parse(OBJECT(dev), prop->value, prop->property, &err);
if (err != NULL) {
- error_propagate(errp, err);
+ assert(prop->user_provided);
+ error_report("Warning: global %s.%s=%s ignored (%s)",
+ prop->driver, prop->property, prop->value,
+ error_get_pretty(err));
+ error_free(err);
return;
}
}
}
-void qdev_prop_set_globals(DeviceState *dev, Error **errp)
+void qdev_prop_set_globals(DeviceState *dev)
{
ObjectClass *class = object_get_class(OBJECT(dev));
do {
- Error *err = NULL;
-
- qdev_prop_set_globals_for_type(dev, object_class_get_name(class),
- &err);
- if (err != NULL) {
- error_propagate(errp, err);
- return;
- }
+ qdev_prop_set_globals_for_type(dev, object_class_get_name(class));
class = object_class_get_parent(class);
} while (class);
}