qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 0/25]: add alpha es40 system emulation (v3)


From: Tristan Gingold
Subject: Re: [Qemu-devel] [PATCH 0/25]: add alpha es40 system emulation (v3)
Date: Wed, 25 Mar 2009 13:53:59 +0100


On Mar 25, 2009, at 1:43 PM, Brian Wheeler wrote:

Neato. I built it and tried to generate the firmware per hw/es40.c and
I get a cpu abort since hwe isn't handled...I tried commenting out the
abort but I still didn't get the rom file.

Argh, try with:

diff --git a/target-alpha/helper.c b/target-alpha/helper.c
index 5165908..fd8f442 100644
--- a/target-alpha/helper.c
+++ b/target-alpha/helper.c
@@ -387,8 +387,7 @@ void cpu_alpha_mtpr_21264 (CPUState *env, int iprn, uint64_t
         unsigned char old_sde1 = env->a21264.sde1;
         env->a21264.i_vptb =
           ((((int64_t)val) << 16) >> 16) & 0xffffffffc0000000ULL;
-        if ((val >> IPR_I_CTL_HWE_SHIFT) & 1)
-            cpu_abort (env, "mtpr i_ctl: hwe not yet handled\n");
+        env->a21264.hwe = (val >> IPR_I_CTL_HWE_SHIFT) & 1;
         env->a21264.sde1 = (val >> IPR_I_CTL_SDE1_SHIFT) & 1;
         env->a21264.iva_48 = (val >> IPR_I_CTL_VA_48_SHIFT) & 3;
         env->a21264.itlb.spe = (val >> IPR_I_CTL_SPE_SHIFT) & 7;
diff --git a/target-alpha/translate.c b/target-alpha/translate.c
index 279786b..27be4d7 100644
--- a/target-alpha/translate.c
+++ b/target-alpha/translate.c
@@ -2429,6 +2429,14 @@ static always_inline void gen_intermediate_code_internal
 #else
     ctx.mem_idx = env->mmu_data_index;
     ctx.pal_mode = env->pal_mode;
+    switch (env->pal_emul) {
+    case PAL_21264:
+        if (env->a21264.hwe && env->a21264.cm == 0)
+            ctx.pal_mode = 1;
+        break;
+    default:
+        break;
+    }
 #endif
     ctx.fen = env->fen;
     num_insns = 0;


That said, I'm really excited to see progress in this area, since the
es40 emulator kind of died out...

Yes!  Thanks.

Tristan.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]