[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v3 18/19] qom: Delete set_default_uuid()
From: |
Eduardo Habkost |
Subject: |
[PATCH v3 18/19] qom: Delete set_default_uuid() |
Date: |
Mon, 23 Nov 2020 14:48:17 -0500 |
The function can be completely replaced by
object_property_set_default(), we don't need it anymore.
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
This is a new patch in v3 of this series.
In v2 of the series, equivalent changes were part of "qom: Use
qlit to represent property defaults".
---
hw/core/qdev-properties-system.c | 8 --------
1 file changed, 8 deletions(-)
diff --git a/hw/core/qdev-properties-system.c b/hw/core/qdev-properties-system.c
index b2df955f2a..07945ea1c0 100644
--- a/hw/core/qdev-properties-system.c
+++ b/hw/core/qdev-properties-system.c
@@ -1077,18 +1077,10 @@ static void set_uuid(Object *obj, Visitor *v, const
char *name, void *opaque,
g_free(str);
}
-static void set_default_uuid(ObjectProperty *op, const Property *prop,
- const QObject *defval)
-{
- QString *qs = qobject_to(QString, defval);
- object_property_set_default_str(op, qstring_get_str(qs));
-}
-
const PropertyInfo qdev_prop_uuid = {
.name = "str",
.description = "UUID (aka GUID) or \"" UUID_VALUE_AUTO
"\" for random value",
.get = get_uuid,
.set = set_uuid,
- .set_default_value = set_default_uuid,
};
--
2.28.0
- Re: [PATCH v3 08/19] qlit: Move qlit_equal_qobject() reference values to array, (continued)
- [PATCH v3 11/19] qom: field_prop_set_default_value() helper, Eduardo Habkost, 2020/11/23
- [PATCH v3 12/19] qom: Replace defval value in Property with QLitObject, Eduardo Habkost, 2020/11/23
- [PATCH v3 13/19] qom: Fix documentation of UUID property type, Eduardo Habkost, 2020/11/23
- [PATCH v3 15/19] qom: Make object_property_set_default() public, Eduardo Habkost, 2020/11/23
- [PATCH v3 16/19] qom: Make PropertyInfo.set_default_value optional, Eduardo Habkost, 2020/11/23
- [PATCH v3 17/19] qom: Delete field_prop_set_default_value_*int(), Eduardo Habkost, 2020/11/23
- [PATCH v3 14/19] qom: Don't ignore defval on UUID property, Eduardo Habkost, 2020/11/23
- [PATCH v3 19/19] qom: Delete set_default_value_bool(), Eduardo Habkost, 2020/11/23
- [PATCH v3 18/19] qom: Delete set_default_uuid(),
Eduardo Habkost <=