The pointed Property structure is accessed read-only. Signed-off-by: Philippe Mathieu-Daudé <phi...@linaro.org> --- hw/core/qdev-properties.c | 2 +- include/hw/qdev-properties.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/hw/core/qdev-properties.c b/hw/core/qdev-properties.c index 858c33830c..baf9a91b29 100644 --- a/hw/core/qdev-properties.c +++ b/hw/core/qdev-properties.c @@ -840,7 +840,7 @@ const PropertyInfo qdev_prop_size = { /* --- object link property --- */ static ObjectProperty *create_link_property(ObjectClass *oc, const char *name, - Property *prop) + const Property *prop) { return object_class_property_add_link(oc, name, prop->link_type, prop->offset, diff --git a/include/hw/qdev-properties.h b/include/hw/qdev-properties.h index 39959c3432..21f399e9a3 100644 --- a/include/hw/qdev-properties.h +++ b/include/hw/qdev-properties.h @@ -37,7 +37,7 @@ struct PropertyInfo { int (*print)(Object *obj, const Property *prop, char *dest, size_t len); void (*set_default_value)(ObjectProperty *op, const Property *prop); ObjectProperty *(*create)(ObjectClass *oc, const char *name, - Property *prop); + const Property *prop); ObjectPropertyAccessor *get; ObjectPropertyAccessor *set; ObjectPropertyRelease *release; -- 2.38.1