unicorn/qemu/target/arm
Peter Maydell a10b65bd47
target/arm: Add ignore_stackfaults argument to v7m_exception_taken()
In the v8M architecture, if the process of taking an exception
results in a further exception this is called a derived exception
(for example, an MPU exception when writing the exception frame to
memory). If the derived exception happens while pushing the initial
stack frame, we must ignore any subsequent possible exception
pushing the callee-saves registers.

In preparation for making the stack writes check for exceptions,
add a return value from v7m_push_stack() and a new parameter to
v7m_exception_taken(), so that the former can tell the latter that
it needs to ignore failures to write to the stack. We also plumb
the argument through to v7m_push_callee_stack(), which is where
the code to ignore the failures will be.

(Note that the v8M ARM pseudocode structures this slightly differently:
derived exceptions cause the attempt to process the original
exception to be abandoned; then at the top level it calls
DerivedLateArrival to prioritize the derived exception and call
TakeException from there. We choose to let the NVIC do the prioritization
and continue forward with a call to TakeException which will then
take either the original or the derived exception. The effect is
the same, but this structure works better for QEMU because we don't
have a convenient top level place to do the abandon-and-retry logic.)

Backports commit 0094ca70e165cfb69882fa2e100d935d45f1c983 from qemu
2018-03-07 08:17:25 -05:00
..
arm-powerctl.c ARM: Factor out ARM on/off PSCI control functions 2018-03-01 23:31:47 -05:00
arm-powerctl.h ARM: Factor out ARM on/off PSCI control functions 2018-03-01 23:31:47 -05:00
arm_ldst.h Fix Thumb-1 BE32 execution and disassembly. 2018-03-02 00:20:11 -05:00
cpu-qom.h Move target-* CPU file into a target/ folder 2018-03-01 22:50:58 -05:00
cpu.c accel/tcg: add size paremeter in tlb_fill() 2018-03-06 10:56:34 -05:00
cpu.h target/arm: Split "get pending exception info" from "acknowledge it" 2018-03-07 08:12:35 -05:00
cpu64.c target-arm: Enable EL2 feature bit on A53 and A57 2018-03-01 23:36:44 -05:00
crypto_helper.c target/arm: Use pointers in crypto helpers 2018-03-06 10:10:06 -05:00
helper-a64.c target/arm: Fix stlxp for aarch64_be 2018-03-06 08:48:12 -05:00
helper-a64.h Move target-* CPU file into a target/ folder 2018-03-01 22:50:58 -05:00
helper.c target/arm: Add ignore_stackfaults argument to v7m_exception_taken() 2018-03-07 08:17:25 -05:00
helper.h target/arm: Use pointers in neon tbl helper 2018-03-06 10:20:21 -05:00
internals.h target/arm: Handle page table walk load failures correctly 2018-03-06 08:55:08 -05:00
iwmmxt_helper.c Move target-* CPU file into a target/ folder 2018-03-01 22:50:58 -05:00
kvm-consts.h arm: better stub version for MISMATCH_CHECK 2018-03-02 00:13:45 -05:00
Makefile.objs ARM: Factor out ARM on/off PSCI control functions 2018-03-01 23:31:47 -05:00
neon_helper.c target/arm: Use pointers in neon zip/uzp helpers 2018-03-06 10:17:51 -05:00
op_addsub.h Move target-* CPU file into a target/ folder 2018-03-01 22:50:58 -05:00
op_helper.c accel/tcg: add size paremeter in tlb_fill() 2018-03-06 10:56:34 -05:00
psci.c fix WFI/WFE length in syndrome register 2018-03-05 11:21:51 -05:00
translate-a64.c target/arm: Use vector infrastructure for aa64 orr/bic immediate 2018-03-06 16:17:42 -05:00
translate.c target/arm: Use pointers in neon tbl helper 2018-03-06 10:20:21 -05:00
translate.h target/arm: Mark disas_set_insn_syndrome inline 2018-03-06 09:20:04 -05:00
unicorn.h Move target-* CPU file into a target/ folder 2018-03-01 22:50:58 -05:00
unicorn_aarch64.c Move target-* CPU file into a target/ folder 2018-03-01 22:50:58 -05:00
unicorn_arm.c Move target-* CPU file into a target/ folder 2018-03-01 22:50:58 -05:00