summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/nds32/task.c10
-rw-r--r--core/riscv-rv32i/task.c10
2 files changed, 2 insertions, 18 deletions
diff --git a/core/nds32/task.c b/core/nds32/task.c
index ea9e10e644..d9aa6beda9 100644
--- a/core/nds32/task.c
+++ b/core/nds32/task.c
@@ -249,14 +249,6 @@ int task_start_called(void)
return start_called;
}
-static int get_sw_int(void)
-{
- /* If this is a SW interrupt */
- if (get_itype() & 8)
- return sw_int_num;
- return 0;
-}
-
/**
* Scheduling system call
*
@@ -351,7 +343,7 @@ void __ram_code start_irq_handler(void)
asm volatile ("smw.adm $r0, [$sp], $r2, 0");
/* If this is a SW interrupt */
if (get_itype() & 8)
- ec_int = get_sw_int();
+ ec_int = sw_int_num;
else
ec_int = chip_get_ec_int();
diff --git a/core/riscv-rv32i/task.c b/core/riscv-rv32i/task.c
index 443a924602..cf734d4078 100644
--- a/core/riscv-rv32i/task.c
+++ b/core/riscv-rv32i/task.c
@@ -225,14 +225,6 @@ int task_start_called(void)
return start_called;
}
-static int __ram_code get_sw_int(void)
-{
- /* If this is a SW interrupt */
- if (get_mcause() == 11)
- return sw_int_num;
- return 0;
-}
-
/**
* Scheduling system call
*
@@ -325,7 +317,7 @@ void __ram_code start_irq_handler(void)
/* If this is a SW interrupt */
if (get_mcause() == 11) {
- ec_int = get_sw_int();
+ ec_int = sw_int_num;
ec_int_group = 16;
} else {
/* Determine interrupt number */