summaryrefslogtreecommitdiff
path: root/cpu-exec.c
diff options
context:
space:
mode:
authorbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2005-12-05 19:59:05 +0000
committerbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2005-12-05 19:59:05 +0000
commit6810e154907c4ed3883f3f9fc03507fe45a679ea (patch)
tree247f7a2b6861c47b61a875aeeec5bc714642d27d /cpu-exec.c
parenta64d4718f1afde08fb74910242e7a7b946c3f162 (diff)
downloadqemu-6810e154907c4ed3883f3f9fc03507fe45a679ea.tar.gz
MIPS halt support - MIPS static state fix (Daniel Jacobowitz)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1689 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'cpu-exec.c')
-rw-r--r--cpu-exec.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/cpu-exec.c b/cpu-exec.c
index 7c056d40b6..128b5ff7a8 100644
--- a/cpu-exec.c
+++ b/cpu-exec.c
@@ -191,7 +191,7 @@ static inline TranslationBlock *tb_find_fast(void)
cs_base = 0;
pc = env->nip;
#elif defined(TARGET_MIPS)
- flags = env->hflags & MIPS_HFLAGS_TMASK;
+ flags = env->hflags & (MIPS_HFLAGS_TMASK | MIPS_HFLAG_BMASK);
cs_base = 0;
pc = env->PC;
#else
@@ -285,6 +285,15 @@ int cpu_exec(CPUState *env1)
return EXCP_HALTED;
}
}
+#elif defined(TARGET_MIPS)
+ if (env1->halted) {
+ if (env1->interrupt_request &
+ (CPU_INTERRUPT_HARD | CPU_INTERRUPT_TIMER)) {
+ env1->halted = 0;
+ } else {
+ return EXCP_HALTED;
+ }
+ }
#endif
cpu_single_env = env1;