[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 7/7] mips_fulong2e: Don't register "cpu" VMState twi
From: |
Andreas Färber |
Subject: |
[Qemu-devel] [PATCH 7/7] mips_fulong2e: Don't register "cpu" VMState twice |
Date: |
Sun, 13 May 2012 20:27:45 +0200 |
From: Juan Quintela <address@hidden>
We have the following simplified callgraph in mips_fulong2e_init():
cpu_init() => cpu_mips_init()
object_new()
mips_cpu_initfn()
cpu_exec_init()
register_savevm(NULL, "cpu", cpu_index, CPU_SAVE_VERSION,
cpu_save, cpu_load, env)
register_savevm(NULL, "cpu", 0, 3, cpu_save, cpu_load, env)
CPU_SAVE_VERSION is defined as 3 in target-mips/cpu.h.
fulong2e instantiates one CPU, so its cpu_index is 0.
Thus the two are fully identical.
Therefore just remove the second call in fulong2e.
Signed-off-by: Juan Quintela <address@hidden>
[AF: Extend explanation in commit message]
Signed-off-by: Andreas Färber <address@hidden>
---
hw/mips_fulong2e.c | 1 -
1 files changed, 0 insertions(+), 1 deletions(-)
diff --git a/hw/mips_fulong2e.c b/hw/mips_fulong2e.c
index 37dc711..1a8df10 100644
--- a/hw/mips_fulong2e.c
+++ b/hw/mips_fulong2e.c
@@ -284,7 +284,6 @@ static void mips_fulong2e_init(ram_addr_t ram_size, const
char *boot_device,
exit(1);
}
- register_savevm(NULL, "cpu", 0, 3, cpu_save, cpu_load, env);
qemu_register_reset(main_cpu_reset, env);
/* fulong 2e has 256M ram. */
--
1.7.7
- [Qemu-devel] [PULL for-1.1-rc2] Fixes from QOM-related series, Andreas Färber, 2012/05/13
- [Qemu-devel] [PATCH 2/7] qom: Documentation addition for object_class_by_name(), Andreas Färber, 2012/05/13
- [Qemu-devel] [PATCH 1/7] target-mips: Remove commented-out function declaration, Andreas Färber, 2012/05/13
- [Qemu-devel] [PATCH 5/7] qdev: Fix adding of ptr properties, Andreas Färber, 2012/05/13
- [Qemu-devel] [PATCH 6/7] pc: Add back PCI.rombar compat property, Andreas Färber, 2012/05/13
- [Qemu-devel] [PATCH 4/7] qdev: Use object_property_print() in info qtree, Andreas Färber, 2012/05/13
- [Qemu-devel] [PATCH 7/7] mips_fulong2e: Don't register "cpu" VMState twice,
Andreas Färber <=
- [Qemu-devel] [PATCH 3/7] target-i386: Defer MCE init, Andreas Färber, 2012/05/13
- Re: [Qemu-devel] [PULL for-1.1-rc2] Fixes from QOM-related series, Luiz Capitulino, 2012/05/14
- Re: [Qemu-devel] [PULL for-1.1-rc2] Fixes from QOM-related series, Anthony Liguori, 2012/05/14