[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 5/5] sparc64: flush translations on mmu context chan
From: |
Igor V. Kovalenko |
Subject: |
[Qemu-devel] [PATCH 5/5] sparc64: flush translations on mmu context change |
Date: |
Sat, 22 May 2010 14:52:40 +0400 |
User-agent: |
StGit/0.15 |
From: Igor V. Kovalenko <address@hidden>
- two pairs of softmmu indexes bind softmmu tlb to cpu tlb in fault handlers
using value of DMMU primary and secondary context registers, so we need to
flush softmmu translations when context registers are changed
Signed-off-by: Igor V. Kovalenko <address@hidden>
---
target-sparc/op_helper.c | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/target-sparc/op_helper.c b/target-sparc/op_helper.c
index 28224b2..edeeb44 100644
--- a/target-sparc/op_helper.c
+++ b/target-sparc/op_helper.c
@@ -2959,9 +2959,15 @@ void helper_st_asi(target_ulong addr, target_ulong val,
int asi, int size)
break;
case 1: // Primary context
env->dmmu.mmu_primary_context = val;
+ /* can be optimized to only flush MMU_USER_IDX
+ and MMU_KERNEL_IDX entries */
+ tlb_flush(env, 1);
break;
case 2: // Secondary context
env->dmmu.mmu_secondary_context = val;
+ /* can be optimized to only flush MMU_USER_SECONDARY_IDX
+ and MMU_KERNEL_SECONDARY_IDX entries */
+ tlb_flush(env, 1);
break;
case 5: // TSB access
DPRINTF_MMU("dmmu TSB write: 0x%016" PRIx64 " -> 0x%016"
- [Qemu-devel] [PATCH 0/5] allow HelenOS to start userspace tasks under qemu-system-sparc64, Igor V. Kovalenko, 2010/05/22
- [Qemu-devel] [PATCH 1/5] sparc64: generate data access exception on RW violation, Igor V. Kovalenko, 2010/05/22
- [Qemu-devel] [PATCH 2/5] sparc64: fix pstate privilege bits, Igor V. Kovalenko, 2010/05/22
- [Qemu-devel] [PATCH 3/5] sparc64: fix dump_mmu to look for global bit in tte value instead of tag, Igor V. Kovalenko, 2010/05/22
- [Qemu-devel] [PATCH 4/5] sparc64: fix mmu context at trap levels above zero, Igor V. Kovalenko, 2010/05/22
- [Qemu-devel] [PATCH 5/5] sparc64: flush translations on mmu context change,
Igor V. Kovalenko <=
- Re: [Qemu-devel] [PATCH 0/5] allow HelenOS to start userspace tasks under qemu-system-sparc64, Blue Swirl, 2010/05/22