Skip to content

Commit 7aeeb92

Browse files
Andy Rossnashif
Andy Ross
authored andcommitted
drivers/timer/xtensa_sys_timer: Add hook for old-style interrupt handling
We still have one platform using (for now) the pre-asm2 integration where the timer interrupt was handled via custom assembly. It calls a function named "_timer_int_handler" always, not the one we register with IRQ_CONNECT. Signed-off-by: Andy Ross <[email protected]>
1 parent 23159ce commit 7aeeb92

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

drivers/timer/xtensa_sys_timer.c

+11
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,17 @@ static void ccompare_isr(void *arg)
5757
z_clock_announce(dticks);
5858
}
5959

60+
/* The legacy Xtensa platform code handles the timer interrupt via a
61+
* special path and must find it via this name. Remove once ASM2 is
62+
* pervasive.
63+
*/
64+
#ifndef CONFIG_XTENSA_ASM2
65+
void _timer_int_handler(void *arg)
66+
{
67+
return ccompare_isr(arg);
68+
}
69+
#endif
70+
6071
int z_clock_driver_init(struct device *device)
6172
{
6273
IRQ_CONNECT(TIMER_IRQ, 0, ccompare_isr, 0, 0);

0 commit comments

Comments
 (0)