summaryrefslogtreecommitdiffstats
path: root/hw/core/qdev-properties.c
diff options
context:
space:
mode:
authorEduardo Habkost2020-12-11 23:05:21 +0100
committerEduardo Habkost2020-12-18 21:20:17 +0100
commitf59c6d223def66df90c0b91415eb96d7ed5e058b (patch)
tree860a4f87463935ac9ee5a2532377de21a2ad13fa /hw/core/qdev-properties.c
parentqdev: Move dev->realized check to qdev_property_set() (diff)
downloadqemu-f59c6d223def66df90c0b91415eb96d7ed5e058b.tar.gz
qemu-f59c6d223def66df90c0b91415eb96d7ed5e058b.tar.xz
qemu-f59c6d223def66df90c0b91415eb96d7ed5e058b.zip
qdev: Make PropertyInfo.create return ObjectProperty*
Returning ObjectProperty* will be useful for new property registration code that will add additional callbacks to ObjectProperty after registering it. Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> Reviewed-by: Igor Mammedov <imammedo@redhat.com> Message-Id: <20201211220529.2290218-25-ehabkost@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Diffstat (limited to 'hw/core/qdev-properties.c')
-rw-r--r--hw/core/qdev-properties.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/hw/core/qdev-properties.c b/hw/core/qdev-properties.c
index 92f48ecbf2..3bb05e7d0d 100644
--- a/hw/core/qdev-properties.c
+++ b/hw/core/qdev-properties.c
@@ -821,13 +821,13 @@ const PropertyInfo qdev_prop_size = {
/* --- object link property --- */
-static void create_link_property(ObjectClass *oc, const char *name,
- Property *prop)
+static ObjectProperty *create_link_property(ObjectClass *oc, const char *name,
+ Property *prop)
{
- object_class_property_add_link(oc, name, prop->link_type,
- prop->offset,
- qdev_prop_allow_set_link_before_realize,
- OBJ_PROP_LINK_STRONG);
+ return object_class_property_add_link(oc, name, prop->link_type,
+ prop->offset,
+ qdev_prop_allow_set_link_before_realize,
+ OBJ_PROP_LINK_STRONG);
}
const PropertyInfo qdev_prop_link = {