Markus Armbruster
981c3dcd94
qdev: Convert to qdev_unrealize() with Coccinelle
For readability, and consistency with qbus_realize().
Coccinelle script:
@ depends on !(file in "hw/core/qdev.c")@
typedef DeviceState;
DeviceState *dev;
symbol false, error_abort;
@@
- object_property_set_bool(OBJECT(dev), false, "realized", &error_abort);
+ qdev_unrealize(dev);
@ depends on !(file in "hw/core/qdev.c") && !(file in "hw/core/bus.c")@
expression dev;
symbol false, error_abort;
@@
- object_property_set_bool(OBJECT(dev), false, "realized", &error_abort);
+ qdev_unrealize(DEVICE(dev));
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Message-Id: <20200610053247.1583243-8-armbru@redhat.com>
2020-06-15 21:36:30 +02:00
..
2020-05-15 07:07:58 +02:00
2020-05-15 07:07:58 +02:00
2020-05-15 07:07:58 +02:00
2020-05-15 07:07:58 +02:00
2020-05-15 07:08:14 +02:00
2020-06-15 21:36:21 +02:00
2020-06-15 21:36:21 +02:00
2020-04-29 08:01:52 +02:00
2020-06-15 21:36:21 +02:00
2020-05-15 07:07:58 +02:00
2020-04-29 08:01:52 +02:00
2020-05-15 07:08:14 +02:00
2020-05-27 15:27:29 +10:00
2020-05-15 07:08:14 +02:00
2020-04-07 08:55:10 +10:00
2020-05-07 11:10:50 +10:00
2020-05-15 07:08:14 +02:00
2020-05-15 07:07:58 +02:00
2020-05-07 11:10:50 +10:00
2019-06-12 13:20:20 +02:00
2020-06-15 21:36:30 +02:00
2020-05-15 07:06:49 +02:00
2020-04-07 08:55:10 +10:00
2020-05-15 07:07:58 +02:00
2020-05-15 07:08:14 +02:00
2020-06-15 21:36:30 +02:00