mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 08:13:54 -06:00
target/nios2: Support division error exception
Division may (optionally) raise a division exception. Since the linux kernel has been prepared for this for some time, enable it by default. Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Message-Id: <20220421151735.31996-42-richard.henderson@linaro.org>
This commit is contained in:
parent
e8d12542ee
commit
345b7a8757
7 changed files with 62 additions and 40 deletions
|
@ -119,6 +119,9 @@ void nios2_cpu_do_interrupt(CPUState *cs)
|
|||
case EXCP_UNALIGND:
|
||||
name = "Misaligned (destination)";
|
||||
break;
|
||||
case EXCP_DIV:
|
||||
name = "DIV error";
|
||||
break;
|
||||
case EXCP_TRAP:
|
||||
name = "TRAP insn";
|
||||
break;
|
||||
|
@ -187,6 +190,7 @@ void nios2_cpu_do_interrupt(CPUState *cs)
|
|||
|
||||
case EXCP_SUPERI:
|
||||
case EXCP_ILLEGAL:
|
||||
case EXCP_DIV:
|
||||
case EXCP_TRAP:
|
||||
do_exception(cpu, cpu->exception_addr, 0, false);
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue