diff options
author | Juan Quintela <quintela@redhat.com> | 2009-09-29 22:48:48 +0200 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2009-10-05 09:32:39 -0500 |
commit | 1f76b9b9b3b78fb51c917d3f3efa6fff1e57a734 (patch) | |
tree | 4bfa519ecc75f869f29d4ce216a8b9a7c5c1203f /target-i386/machine.c | |
parent | 6b0e766f4ca6fece18d12d8764d75eab8895b4bb (diff) |
x86: hflags is not modified at all, just save it directly
Signed-off-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'target-i386/machine.c')
-rw-r--r-- | target-i386/machine.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/target-i386/machine.c b/target-i386/machine.c index e5a060fcc2..adbb16fb87 100644 --- a/target-i386/machine.c +++ b/target-i386/machine.c @@ -27,7 +27,6 @@ void cpu_save(QEMUFile *f, void *opaque) { CPUState *env = opaque; uint16_t fptag, fpus, fpuc, fpregs_format; - uint32_t hflags; int32_t a20_mask; int32_t pending_irq; int i, bit; @@ -38,8 +37,7 @@ void cpu_save(QEMUFile *f, void *opaque) qemu_put_betls(f, &env->regs[i]); qemu_put_betls(f, &env->eip); qemu_put_betls(f, &env->eflags); - hflags = env->hflags; /* XXX: suppress most of the redundant hflags */ - qemu_put_be32s(f, &hflags); + qemu_put_be32s(f, &env->hflags); /* FPU */ fpuc = env->fpuc; @@ -202,7 +200,6 @@ int cpu_load(QEMUFile *f, void *opaque, int version_id) { CPUState *env = opaque; int i, guess_mmx; - uint32_t hflags; uint16_t fpus, fpuc, fptag, fpregs_format; int32_t a20_mask; int32_t pending_irq; @@ -214,7 +211,7 @@ int cpu_load(QEMUFile *f, void *opaque, int version_id) qemu_get_betls(f, &env->regs[i]); qemu_get_betls(f, &env->eip); qemu_get_betls(f, &env->eflags); - qemu_get_be32s(f, &hflags); + qemu_get_be32s(f, &env->hflags); qemu_get_be16s(f, &fpuc); qemu_get_be16s(f, &fpus); @@ -381,9 +378,7 @@ int cpu_load(QEMUFile *f, void *opaque, int version_id) if (version_id >= 11) { qemu_get_be64s(f, &env->tsc_aux); } - /* XXX: ensure compatiblity for halted bit ? */ - /* XXX: compute redundant hflags bits */ - env->hflags = hflags; + tlb_flush(env, 1); return 0; } |