aboutsummaryrefslogtreecommitdiff
path: root/target-mips/op_helper.c
diff options
context:
space:
mode:
authorbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2006-05-22 22:14:43 +0000
committerbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2006-05-22 22:14:43 +0000
commitba9a74dae0bb696ceab1ee2291cee43ef241a639 (patch)
treed07257af8d0dfc30f0376b2cec0538187aaf6f13 /target-mips/op_helper.c
parent3d9fb9fefe3f4e209b57443bed18691a2c6f3e7a (diff)
fix wrong bitmasks for CP0_Context and CP0_EntryHi (Thiemo Seufer)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1937 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'target-mips/op_helper.c')
-rw-r--r--target-mips/op_helper.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/target-mips/op_helper.c b/target-mips/op_helper.c
index 03e13a40f8..fbd693fb23 100644
--- a/target-mips/op_helper.c
+++ b/target-mips/op_helper.c
@@ -342,7 +342,7 @@ void do_mtc0 (int reg, int sel)
rn = "EntryLo1";
break;
case 4:
- val = (env->CP0_Context & 0xFF000000) | (T0 & 0x00FFFFF0);
+ val = (env->CP0_Context & 0xFF800000) | (T0 & 0x007FFFF0);
old = env->CP0_Context;
env->CP0_Context = val;
rn = "Context";
@@ -366,7 +366,7 @@ void do_mtc0 (int reg, int sel)
rn = "Count";
break;
case 10:
- val = T0 & 0xFFFFF0FF;
+ val = T0 & 0xFFFFE0FF;
old = env->CP0_EntryHi;
env->CP0_EntryHi = val;
/* If the ASID changes, flush qemu's TLB. */