From 1c05eb651c45830ae6f4256883493a4d5e8f6f68 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Fri, 4 Nov 2016 19:29:54 -0600 Subject: [PATCH 1/2] LM32: lm32_vectors.S needs to call lm32_doirq(), passing two parameters --- arch/misoc/src/lm32/lm32_vectors.S | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/arch/misoc/src/lm32/lm32_vectors.S b/arch/misoc/src/lm32/lm32_vectors.S index 80645f834d..f3dd955f86 100644 --- a/arch/misoc/src/lm32/lm32_vectors.S +++ b/arch/misoc/src/lm32/lm32_vectors.S @@ -38,7 +38,7 @@ * Included Files ****************************************************************************/ -#include +#include /**************************************************************************** * Exception handlers - Must be 32 bytes long. @@ -121,12 +121,11 @@ _interrupt_handler: _syscall_handler: sw (sp+0), ra calli .save_all - rcsr r1, IP - calli lm32_swint + mvi r1, MISOC_IRQ_SWINT + rcsr r2, IP + calli lm32_doirq bi .restore_all_and_eret nop - nop - nop _do_reset: /* Setup stack and global pointer */ From 3f150daf9657df24b3049ed2844c1a1f104a3fa0 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Fri, 4 Nov 2016 19:41:43 -0600 Subject: [PATCH 2/2] LM32: Oops, missed one line of code in the manual application of a patch --- arch/misoc/src/lm32/lm32_vectors.S | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/misoc/src/lm32/lm32_vectors.S b/arch/misoc/src/lm32/lm32_vectors.S index f3dd955f86..4a0e6cd095 100644 --- a/arch/misoc/src/lm32/lm32_vectors.S +++ b/arch/misoc/src/lm32/lm32_vectors.S @@ -120,6 +120,7 @@ _interrupt_handler: _syscall_handler: sw (sp+0), ra + addi ea, ea, 4 calli .save_all mvi r1, MISOC_IRQ_SWINT rcsr r2, IP