aboutsummaryrefslogtreecommitdiff
path: root/target-sh4/op_helper.c
diff options
context:
space:
mode:
Diffstat (limited to 'target-sh4/op_helper.c')
-rw-r--r--target-sh4/op_helper.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/target-sh4/op_helper.c b/target-sh4/op_helper.c
index 163858f560..b299576651 100644
--- a/target-sh4/op_helper.c
+++ b/target-sh4/op_helper.c
@@ -55,15 +55,14 @@ static void cpu_restore_state_from_retaddr(void *retaddr)
#define SHIFT 3
#include "softmmu_template.h"
-void tlb_fill(target_ulong addr, int is_write, int mmu_idx, void *retaddr)
+void tlb_fill(CPUState *env1, target_ulong addr, int is_write, int mmu_idx,
+ void *retaddr)
{
CPUState *saved_env;
int ret;
- /* XXX: hack to restore env in all cases, even if not called from
- generated code */
saved_env = env;
- env = cpu_single_env;
+ env = env1;
ret = cpu_sh4_handle_mmu_fault(env, addr, is_write, mmu_idx);
if (ret) {
/* now we have a real cpu fault */