summary refs log tree commit diff stats
path: root/hw/misc/macio/pmu.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/misc/macio/pmu.c')
-rw-r--r--hw/misc/macio/pmu.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/hw/misc/macio/pmu.c b/hw/misc/macio/pmu.c
index 598d8e7517..09022995ad 100644
--- a/hw/misc/macio/pmu.c
+++ b/hw/misc/macio/pmu.c
@@ -735,14 +735,11 @@ static void pmu_reset(DeviceState *dev)
 static void pmu_realize(DeviceState *dev, Error **errp)
 {
     PMUState *s = VIA_PMU(dev);
-    Error *err = NULL;
     SysBusDevice *sbd;
     ADBBusState *adb_bus = &s->adb_bus;
     struct tm tm;
 
-    sysbus_realize(SYS_BUS_DEVICE(&s->mos6522_pmu), &err);
-    if (err) {
-        error_propagate(errp, err);
+    if (!sysbus_realize(SYS_BUS_DEVICE(&s->mos6522_pmu), errp)) {
         return;
     }