]> xenbits.xensource.com Git - qemu-xen.git/commitdiff
spapr: Abort on delete failure in spapr_drc_release()
authorDavid Gibson <david@gibson.dropbear.id.au>
Thu, 13 Jul 2017 00:52:39 +0000 (10:52 +1000)
committerDavid Gibson <david@gibson.dropbear.id.au>
Mon, 17 Jul 2017 05:07:05 +0000 (15:07 +1000)
We currently ignore errors from the object_property_del() in
spapr_drc_release().  But the only way that could fail is if the property
doesn't exist, in which case it's a bug that we're in spapr_drc_release()
at all.  So change from ignoring to abort()ing on errors.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
hw/ppc/spapr_drc.c

index 7f872a4803f1b583c5c489394279c2424d831e57..fd5614094dd0cd295c53980e49a3cfb504454256 100644 (file)
@@ -367,7 +367,7 @@ static void spapr_drc_release(sPAPRDRConnector *drc)
     g_free(drc->fdt);
     drc->fdt = NULL;
     drc->fdt_start_offset = 0;
-    object_property_del(OBJECT(drc), "device", NULL);
+    object_property_del(OBJECT(drc), "device", &error_abort);
     drc->dev = NULL;
 }