From df32c8d436d4eb3f40b00647ca0df2bbc7f6bf6f Mon Sep 17 00:00:00 2001 From: Juan Quintela Date: Mon, 11 Jan 2016 12:40:26 +0000 Subject: target-sparc: Convert to VMStateDescription Convert the SPARC CPU from cpu_load/save functions to VMStateDescription. We preserve migration compatibility with the previous version (required for SPARC32 but not necessarily for SPARC64). Signed-off-by: Juan Quintela [PMM: * Rebase and update to apply to master * VMSTATE_STRUCT_POINTER now takes type, not pointer-to-type * QEMUTimer* are migrated via VMSTATE_TIMER_PTR * Put CPUTimer vmstate struct inside TARGET_SPARC64 ifdef * Convert handling of PSR to use a vmstate_psr, like Alpha and ARM ] Signed-off-by: Peter Maydell Signed-off-by: Mark Cave-Ayland --- hw/sparc64/sun4u.c | 24 ------------------------ 1 file changed, 24 deletions(-) (limited to 'hw/sparc64') diff --git a/hw/sparc64/sun4u.c b/hw/sparc64/sun4u.c index 1925a1cef9..861727f7e3 100644 --- a/hw/sparc64/sun4u.c +++ b/hw/sparc64/sun4u.c @@ -358,30 +358,6 @@ typedef struct ResetData { uint64_t prom_addr; } ResetData; -void cpu_put_timer(QEMUFile *f, CPUTimer *s) -{ - qemu_put_be32s(f, &s->frequency); - qemu_put_be32s(f, &s->disabled); - qemu_put_be64s(f, &s->disabled_mask); - qemu_put_be32s(f, &s->npt); - qemu_put_be64s(f, &s->npt_mask); - qemu_put_sbe64s(f, &s->clock_offset); - - timer_put(f, s->qtimer); -} - -void cpu_get_timer(QEMUFile *f, CPUTimer *s) -{ - qemu_get_be32s(f, &s->frequency); - qemu_get_be32s(f, &s->disabled); - qemu_get_be64s(f, &s->disabled_mask); - qemu_get_be32s(f, &s->npt); - qemu_get_be64s(f, &s->npt_mask); - qemu_get_sbe64s(f, &s->clock_offset); - - timer_get(f, s->qtimer); -} - static CPUTimer *cpu_timer_create(const char *name, SPARCCPU *cpu, QEMUBHFunc *cb, uint32_t frequency, uint64_t disabled_mask, uint64_t npt_mask) -- cgit v1.2.3