From 4246e225c0e8fbcf17051aa83a4198293c007cc4 Mon Sep 17 00:00:00 2001 From: Max Filippov Date: Wed, 12 Feb 2014 14:35:56 +0400 Subject: target-xtensa: implement do_unassigned_access callback Depending on access type raise either InstrPIFDataError or LoadStorePIFDataError exception. Signed-off-by: Max Filippov --- target-xtensa/op_helper.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'target-xtensa/op_helper.c') diff --git a/target-xtensa/op_helper.c b/target-xtensa/op_helper.c index 49e86343ed..be657e615d 100644 --- a/target-xtensa/op_helper.c +++ b/target-xtensa/op_helper.c @@ -71,6 +71,20 @@ void tlb_fill(CPUState *cs, } } +void xtensa_cpu_do_unassigned_access(CPUState *cs, hwaddr addr, + bool is_write, bool is_exec, int opaque, + unsigned size) +{ + XtensaCPU *cpu = XTENSA_CPU(cs); + CPUXtensaState *env = &cpu->env; + + HELPER(exception_cause_vaddr)(env, env->pc, + is_exec ? + INSTR_PIF_ADDR_ERROR_CAUSE : + LOAD_STORE_PIF_ADDR_ERROR_CAUSE, + is_exec ? addr : cs->mem_io_vaddr); +} + static void tb_invalidate_virtual_addr(CPUXtensaState *env, uint32_t vaddr) { uint32_t paddr; -- cgit v1.2.3