From: Emmanuel Blot <[email protected]> Attach a description to the dynamic "temperature" QOM property so it is documented in the QOM introspection output (qom-list-properties). The value is expressed in millidegrees Celsius.
Signed-off-by: Emmanuel Blot <[email protected]> Reviewed-by: Cédric Le Goater <[email protected]> Link: https://lore.kernel.org/qemu-devel/[email protected] Signed-off-by: Cédric Le Goater <[email protected]> --- hw/sensor/tmp105.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/sensor/tmp105.c b/hw/sensor/tmp105.c index 5c77f991cc20..fefa66171170 100644 --- a/hw/sensor/tmp105.c +++ b/hw/sensor/tmp105.c @@ -367,6 +367,8 @@ static void tmp105_initfn(Object *obj) object_property_add(obj, "temperature", "int", tmp105_get_temperature, tmp105_set_temperature, NULL, NULL); + object_property_set_description(obj, "temperature", + "Temperature, in millidegrees Celsius"); } static void tmp105_class_init(ObjectClass *klass, const void *data) -- 2.55.0
