diff options
author | Igor Kovalenko <igor.v.kovalenko@gmail.com> | 2009-07-27 01:49:04 +0400 |
---|---|---|
committer | Blue Swirl <blauwirbel@gmail.com> | 2009-07-27 05:43:22 +0000 |
commit | 6e8e7d4c092951f417297120e3d3cc28840a045b (patch) | |
tree | 4051a100ff5bca5965d2bf07be3ebf8af8c91d19 /target-sparc/machine.c | |
parent | 33b544ba5c78c656cef6f34880cd3670d170a83f (diff) | |
download | qemu-6e8e7d4c092951f417297120e3d3cc28840a045b.tar.gz |
sparc64 name mmu registers and general cleanup
- add names to mmu registers, this helps understanding the code which
uses/modifies them.
- fold i/d mmu tlb entries tag and tte arrays into arrays of tlb entries
- extract demap_tlb routine (code duplication)
- extract replace_tlb routine (code duplication)
- flush qemu tlb translations when replacing sparc64 mmu tlb entries
I have no test case which demands flushing qemu translations,
and this patch should have no other visible changes to runtime.
Signed-off-by: igor.v.kovalenko@gmail.com
--
Kind regards,
Igor V. Kovalenko
Diffstat (limited to 'target-sparc/machine.c')
-rw-r--r-- | target-sparc/machine.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/target-sparc/machine.c b/target-sparc/machine.c index 4984e8d886..3d196eedc9 100644 --- a/target-sparc/machine.c +++ b/target-sparc/machine.c @@ -52,10 +52,10 @@ void cpu_save(QEMUFile *f, void *opaque) qemu_put_be64s(f, &env->dmmuregs[i]); } for (i = 0; i < 64; i++) { - qemu_put_be64s(f, &env->itlb_tag[i]); - qemu_put_be64s(f, &env->itlb_tte[i]); - qemu_put_be64s(f, &env->dtlb_tag[i]); - qemu_put_be64s(f, &env->dtlb_tte[i]); + qemu_put_be64s(f, &env->itlb[i].tag); + qemu_put_be64s(f, &env->itlb[i].tte); + qemu_put_be64s(f, &env->dtlb[i].tag); + qemu_put_be64s(f, &env->dtlb[i].tte); } qemu_put_be32s(f, &env->mmu_version); for (i = 0; i < MAXTL_MAX; i++) { @@ -148,10 +148,10 @@ int cpu_load(QEMUFile *f, void *opaque, int version_id) qemu_get_be64s(f, &env->dmmuregs[i]); } for (i = 0; i < 64; i++) { - qemu_get_be64s(f, &env->itlb_tag[i]); - qemu_get_be64s(f, &env->itlb_tte[i]); - qemu_get_be64s(f, &env->dtlb_tag[i]); - qemu_get_be64s(f, &env->dtlb_tte[i]); + qemu_get_be64s(f, &env->itlb[i].tag); + qemu_get_be64s(f, &env->itlb[i].tte); + qemu_get_be64s(f, &env->dtlb[i].tag); + qemu_get_be64s(f, &env->dtlb[i].tte); } qemu_get_be32s(f, &env->mmu_version); for (i = 0; i < MAXTL_MAX; i++) { |