diff mbox series

[PULL,2/8] target/moxie: Fix tlb_fill

Message ID 20171229193113.11753-3-richard.henderson@linaro.org
State Accepted
Commit 1f5940e4642f4a2c64bcba724eaff3c28ae38c54
Headers show
Series tcg queued patches | expand

Commit Message

Richard Henderson Dec. 29, 2017, 7:31 p.m. UTC
We should not exit unless moxie_cpu_handle_mmu_fault has failed.

Reviewed-by: Peter Maydell <peter.maydell@linaro.org>

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>

---
 target/moxie/helper.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

-- 
2.14.3
diff mbox series

Patch

diff --git a/target/moxie/helper.c b/target/moxie/helper.c
index 2ecee89f11..6890ffd71c 100644
--- a/target/moxie/helper.c
+++ b/target/moxie/helper.c
@@ -36,9 +36,8 @@  void tlb_fill(CPUState *cs, target_ulong addr, MMUAccessType access_type,
 
     ret = moxie_cpu_handle_mmu_fault(cs, addr, access_type, mmu_idx);
     if (unlikely(ret)) {
-        cpu_restore_state(cs, retaddr);
+        cpu_loop_exit_restore(cs, retaddr);
     }
-    cpu_loop_exit(cs);
 }
 
 void helper_raise_exception(CPUMoxieState *env, int ex)