aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGonglei <arei.gonglei@huawei.com>2015-07-10 08:51:29 +0800
committerPaolo Bonzini <pbonzini@redhat.com>2015-07-16 20:00:20 +0200
commit5348c62cab309b68ecd13a33c9f21e8d6071af72 (patch)
treee87481836a29262505314e45d538fc24c6331141
parent586d2142a9f1aa5a1dceb0941e7b3f0953974a8b (diff)
downloadqemu-arm-5348c62cab309b68ecd13a33c9f21e8d6071af72.tar.gz
arm/xlnx-zynqmp: fix memory leak
fix CID 1311372. Signed-off-by: Gonglei <arei.gonglei@huawei.com> Message-Id: <1436489490-236-4-git-send-email-arei.gonglei@huawei.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
-rw-r--r--hw/arm/xlnx-zynqmp.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/hw/arm/xlnx-zynqmp.c b/hw/arm/xlnx-zynqmp.c
index 5e7207846e..62ef4ceb32 100644
--- a/hw/arm/xlnx-zynqmp.c
+++ b/hw/arm/xlnx-zynqmp.c
@@ -144,6 +144,7 @@ static void xlnx_zynqmp_realize(DeviceState *dev, Error **errp)
} else {
s->boot_cpu_ptr = &s->apu_cpu[i];
}
+ g_free(name);
object_property_set_int(OBJECT(&s->apu_cpu[i]), GIC_BASE_ADDR,
"reset-cbar", &err);
@@ -181,6 +182,7 @@ static void xlnx_zynqmp_realize(DeviceState *dev, Error **errp)
} else {
s->boot_cpu_ptr = &s->rpu_cpu[i];
}
+ g_free(name);
object_property_set_bool(OBJECT(&s->rpu_cpu[i]), true, "reset-hivecs",
&err);