aboutsummaryrefslogtreecommitdiff
path: root/hw/intc
diff options
context:
space:
mode:
authorMarkus Armbruster <armbru@redhat.com>2020-06-10 07:32:38 +0200
committerMarkus Armbruster <armbru@redhat.com>2020-06-15 22:06:04 +0200
commit5a147c8c51d42fcdf5befc2982715b4b407f612e (patch)
tree74c0340ac0e1d8cc99dab09f08db45e5ea6bab37 /hw/intc
parentdb873cc5d1a4aaa67eea87768d504b2f89d88738 (diff)
downloadqemu-5a147c8c51d42fcdf5befc2982715b4b407f612e.zip
qemu-5a147c8c51d42fcdf5befc2982715b4b407f612e.tar.gz
qemu-5a147c8c51d42fcdf5befc2982715b4b407f612e.tar.bz2
sysbus: Convert qdev_set_parent_bus() use with Coccinelle, part 3
These are init/realize pairs produced by the previous commit's Coccinelle script where the argument test doesn't quite match. They need even more careful review. Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Message-Id: <20200610053247.1583243-50-armbru@redhat.com>
Diffstat (limited to 'hw/intc')
-rw-r--r--hw/intc/armv7m_nvic.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/hw/intc/armv7m_nvic.c b/hw/intc/armv7m_nvic.c
index f035079..af9f4c5 100644
--- a/hw/intc/armv7m_nvic.c
+++ b/hw/intc/armv7m_nvic.c
@@ -2640,8 +2640,7 @@ static void armv7m_nvic_realize(DeviceState *dev, Error **errp)
s->num_prio_bits = arm_feature(&s->cpu->env, ARM_FEATURE_V7) ? 8 : 2;
- object_property_set_bool(OBJECT(&s->systick[M_REG_NS]), true,
- "realized", &err);
+ sysbus_realize(SYS_BUS_DEVICE(&s->systick[M_REG_NS]), &err);
if (err != NULL) {
error_propagate(errp, err);
return;
@@ -2735,8 +2734,8 @@ static void armv7m_nvic_instance_init(Object *obj)
NVICState *nvic = NVIC(obj);
SysBusDevice *sbd = SYS_BUS_DEVICE(obj);
- sysbus_init_child_obj(obj, "systick-reg-ns", &nvic->systick[M_REG_NS],
- sizeof(nvic->systick[M_REG_NS]), TYPE_SYSTICK);
+ object_initialize_child(obj, "systick-reg-ns", &nvic->systick[M_REG_NS],
+ TYPE_SYSTICK);
/* We can't initialize the secure systick here, as we don't know
* yet if we need it.
*/