aboutsummaryrefslogtreecommitdiff
path: root/hw/ppc/pnv_psi.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/ppc/pnv_psi.c')
-rw-r--r--hw/ppc/pnv_psi.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/hw/ppc/pnv_psi.c b/hw/ppc/pnv_psi.c
index 75b8ae9703..7efe6e138f 100644
--- a/hw/ppc/pnv_psi.c
+++ b/hw/ppc/pnv_psi.c
@@ -510,8 +510,7 @@ static void pnv_psi_power8_realize(DeviceState *dev, Error **errp)
error_propagate(errp, err);
return;
}
- qdev_realize(DEVICE(ics), NULL, &err);
- if (err) {
+ if (!qdev_realize(DEVICE(ics), NULL, &err)) {
error_propagate(errp, err);
return;
}
@@ -851,8 +850,7 @@ static void pnv_psi_power9_realize(DeviceState *dev, Error **errp)
object_property_set_int(OBJECT(xsrc), PSIHB9_NUM_IRQS, "nr-irqs",
&error_fatal);
object_property_set_link(OBJECT(xsrc), OBJECT(psi), "xive", &error_abort);
- qdev_realize(DEVICE(xsrc), NULL, &local_err);
- if (local_err) {
+ if (!qdev_realize(DEVICE(xsrc), NULL, &local_err)) {
error_propagate(errp, local_err);
return;
}