[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v2 04/20] target-s390: move back cpu_exec_init() to
From: |
Laurent Vivier |
Subject: |
[Qemu-devel] [PATCH v2 04/20] target-s390: move back cpu_exec_init() to init |
Date: |
Thu, 13 Oct 2016 18:24:46 +0200 |
We have now the cpu_exec_realize() in realize,
so the init part must be in init.
I've removed the cannot_destroy_with_object_finalize_yet field as
it should be removed by commit c6644fc.
(tested with QOM command provided by commit 4c315c27 with
"z890.3-s390-cpu")
CC: Richard Henderson <address@hidden>
Signed-off-by: Laurent Vivier <address@hidden>
---
target-s390x/cpu.c | 8 +-------
1 file changed, 1 insertion(+), 7 deletions(-)
diff --git a/target-s390x/cpu.c b/target-s390x/cpu.c
index 4339da1..f92adad 100644
--- a/target-s390x/cpu.c
+++ b/target-s390x/cpu.c
@@ -207,7 +207,6 @@ static void s390_cpu_realizefn(DeviceState *dev, Error
**errp)
goto out;
}
- cpu_exec_init(cs);
cpu_exec_realize(cs, &err);
if (err != NULL) {
goto out;
@@ -290,6 +289,7 @@ static void s390_cpu_initfn(Object *obj)
cs->env_ptr = env;
cs->halted = 1;
cs->exception_index = EXCP_HLT;
+ cpu_exec_init(cs);
object_property_add(OBJECT(cpu), "id", "int64_t", s390x_cpu_get_id,
s390x_cpu_set_id, NULL, NULL, NULL);
s390_cpu_model_register_props(obj);
@@ -441,12 +441,6 @@ static void s390_cpu_class_init(ObjectClass *oc, void
*data)
cc->gdb_core_xml_file = "s390x-core64.xml";
cc->gdb_arch_name = s390_gdb_arch_name;
- /*
- * Reason: s390_cpu_realizefn() calls cpu_exec_init(), which saves
- * the object in cpus -> dangling pointer after final
- * object_unref().
- */
- dc->cannot_destroy_with_object_finalize_yet = true;
s390_cpu_model_class_register_props(oc);
}
--
2.7.4
[Qemu-devel] [PATCH v2 03/20] target-ppc: move back cpu_exec_init() to init, Laurent Vivier, 2016/10/13
[Qemu-devel] [PATCH v2 04/20] target-s390: move back cpu_exec_init() to init,
Laurent Vivier <=
[Qemu-devel] [PATCH v2 07/20] target-cris: move cpu_exec_realize() to realize function, Laurent Vivier, 2016/10/13
[Qemu-devel] [PATCH v2 06/20] target-alpha: move cpu_exec_realize() to realize function, Laurent Vivier, 2016/10/13
[Qemu-devel] [PATCH v2 05/20] target-arm: move cpu_exec_realize() to realize function, Laurent Vivier, 2016/10/13
[Qemu-devel] [PATCH v2 08/20] target-lm32: move cpu_exec_realize() to realize function, Laurent Vivier, 2016/10/13
[Qemu-devel] [PATCH v2 09/20] target-m68k: move cpu_exec_realize() to realize function, Laurent Vivier, 2016/10/13
[Qemu-devel] [PATCH v2 10/20] target-microblaze: move cpu_exec_realize() to realize function, Laurent Vivier, 2016/10/13
[Qemu-devel] [PATCH v2 11/20] target-mips: move cpu_exec_realize() to realize function, Laurent Vivier, 2016/10/13
[Qemu-devel] [PATCH v2 12/20] target-moxie: move cpu_exec_realize() to realize function, Laurent Vivier, 2016/10/13
[Qemu-devel] [PATCH v2 13/20] target-openrisc: move cpu_exec_realize() to realize function, Laurent Vivier, 2016/10/13
[Qemu-devel] [PATCH v2 14/20] target-sh4: move cpu_exec_realize() to realize function, Laurent Vivier, 2016/10/13