arch/tricore: fix tricore_doirq function local var "regs" not initialized issue
In tricore_doirq, local variable regs is firstly used without initiazlied, this is a bug Signed-off-by: Chengdong Wang <wangchengdong@lixiang.com>
This commit is contained in:
parent
9413b6f331
commit
dd51d9a3fc
1 changed files with 3 additions and 3 deletions
|
|
@ -55,14 +55,14 @@ IFX_INTERRUPT_INTERNAL(tricore_doirq, 0, 255)
|
||||||
Ifx_CPU_ICR icr;
|
Ifx_CPU_ICR icr;
|
||||||
uintptr_t *regs;
|
uintptr_t *regs;
|
||||||
|
|
||||||
|
icr.U = __mfcr(CPU_ICR);
|
||||||
|
regs = (uintptr_t *)__mfcr(CPU_PCXI);
|
||||||
|
|
||||||
if (*running_task != NULL)
|
if (*running_task != NULL)
|
||||||
{
|
{
|
||||||
(*running_task)->xcp.regs = regs;
|
(*running_task)->xcp.regs = regs;
|
||||||
}
|
}
|
||||||
|
|
||||||
icr.U = __mfcr(CPU_ICR);
|
|
||||||
regs = (uintptr_t *)__mfcr(CPU_PCXI);
|
|
||||||
|
|
||||||
board_autoled_on(LED_INIRQ);
|
board_autoled_on(LED_INIRQ);
|
||||||
|
|
||||||
/* Nested interrupts are not supported */
|
/* Nested interrupts are not supported */
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue