[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 6/9] unicore32-softmmu: add generic cpu state sa
From: |
Andreas Färber |
Subject: |
Re: [Qemu-devel] [PATCH 6/9] unicore32-softmmu: add generic cpu state save/load functions |
Date: |
Fri, 25 May 2012 13:44:08 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:12.0) Gecko/20120421 Thunderbird/12.0 |
Am 25.05.2012 13:29, schrieb Guan Xuetao:
> This patch adds generic cpu state save/load functions for UniCore32 ISA.
> All architecture related registers are saved or loaded, and no optimization.
>
> Signed-off-by: Guan Xuetao <address@hidden>
> ---
> target-unicore32/machine.c | 99
> ++++++++++++++++++++++++++++++++++++++++++++
> 1 files changed, 99 insertions(+), 0 deletions(-)
> create mode 100644 target-unicore32/machine.c
>
> diff --git a/target-unicore32/machine.c b/target-unicore32/machine.c
> new file mode 100644
> index 0000000..e8c52cd
> --- /dev/null
> +++ b/target-unicore32/machine.c
> @@ -0,0 +1,99 @@
> +/*
> + * Generic machine functions for UniCore32 ISA
> + *
> + * Copyright (C) 2010-2012 Guan Xuetao
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License version 2 as
> + * published by the Free Software Foundation, or any later version.
> + * See the COPYING file in the top-level directory.
> + */
> +#include "hw/hw.h"
> +
> +void cpu_save(QEMUFile *f, void *opaque)
> +{
> + int i;
> + CPUUniCore32State *env = (CPUUniCore32State *)opaque;
> +
> + for (i = 0; i < 32; i++) {
> + qemu_put_be32(f, env->regs[i]);
> + }
> + qemu_put_be32(f, cpu_asr_read(env));
> + qemu_put_be32(f, env->bsr);
[snip]
Please use VMState instead.
Andreas
--
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg
- [Qemu-devel] [PATCH 8/9] unicore32-softmmu: add config and makefile support, (continued)
- [Qemu-devel] [PATCH 9/9] unicore32-softmmu: add maintainer information, Guan Xuetao, 2012/05/25
- [Qemu-devel] [PATCH 7/9] unicore32-softmmu: add puv3 soc support, Guan Xuetao, 2012/05/25
- [Qemu-devel] [PATCH 6/9] unicore32-softmmu: add generic cpu state save/load functions, Guan Xuetao, 2012/05/25
- Re: [Qemu-devel] [PATCH 0/9] *** SUBJECT HERE ***, Guan Xuetao, 2012/05/25
- Re: [Qemu-devel] [PATCH 0/9] *** SUBJECT HERE ***, Andreas Färber, 2012/05/25