summaryrefslogtreecommitdiffstats
path: root/target-mips
diff options
context:
space:
mode:
authorLeon Alrae2015-01-26 17:17:39 +0100
committerLeon Alrae2015-02-13 15:11:29 +0100
commitd3b1979d7b37c7fa6b187442e0990afa6f88fe3b (patch)
tree9a376d12c44b5ce7f618f2c93858af151471c621 /target-mips
parenttarget-mips: ll and lld cause AdEL exception for unaligned address (diff)
downloadqemu-d3b1979d7b37c7fa6b187442e0990afa6f88fe3b.tar.gz
qemu-d3b1979d7b37c7fa6b187442e0990afa6f88fe3b.tar.xz
qemu-d3b1979d7b37c7fa6b187442e0990afa6f88fe3b.zip
target-mips: use CP0EnLo_XI instead of magic number
Signed-off-by: Leon Alrae <leon.alrae@imgtec.com> Reviewed-by: Maciej W. Rozycki <macro@linux-mips.org>
Diffstat (limited to 'target-mips')
-rw-r--r--target-mips/translate.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/target-mips/translate.c b/target-mips/translate.c
index a24863c09f..b80af98593 100644
--- a/target-mips/translate.c
+++ b/target-mips/translate.c
@@ -4947,7 +4947,7 @@ static void gen_mfc0(DisasContext *ctx, TCGv arg, int reg, int sel)
#if defined(TARGET_MIPS64)
if (ctx->rxi) {
TCGv tmp = tcg_temp_new();
- tcg_gen_andi_tl(tmp, arg, (3ull << 62));
+ tcg_gen_andi_tl(tmp, arg, (3ull << CP0EnLo_XI));
tcg_gen_shri_tl(tmp, tmp, 32);
tcg_gen_or_tl(arg, arg, tmp);
tcg_temp_free(tmp);
@@ -5002,7 +5002,7 @@ static void gen_mfc0(DisasContext *ctx, TCGv arg, int reg, int sel)
#if defined(TARGET_MIPS64)
if (ctx->rxi) {
TCGv tmp = tcg_temp_new();
- tcg_gen_andi_tl(tmp, arg, (3ull << 62));
+ tcg_gen_andi_tl(tmp, arg, (3ull << CP0EnLo_XI));
tcg_gen_shri_tl(tmp, tmp, 32);
tcg_gen_or_tl(arg, arg, tmp);
tcg_temp_free(tmp);