Skip to content

Commit d7bb10d

Browse files
natto1784kartben
authored andcommitted
drivers: timer: ti_dmtimer: provide timer IRQ for tests
This patch allows ti_dmtimer to provide the symbol z_sys_timer_irq_for_test whenever tests are enabled. Not providing this results in failing some kernel test cases which require this symbol. Signed-off-by: Amneesh Singh <a-singh7@ti.com>
1 parent f3bc550 commit d7bb10d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

drivers/timer/ti_dmtimer.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@
2121
#define TIMER_IRQ_PRIO DT_INST_IRQ(0, priority)
2222
#define TIMER_IRQ_FLAGS DT_INST_IRQ(0, flags)
2323

24+
#if defined(CONFIG_TEST)
25+
const int32_t z_sys_timer_irq_for_test = TIMER_IRQ_NUM;
26+
#endif
27+
2428
#define CYC_PER_TICK ((uint32_t)(sys_clock_hw_cycles_per_sec() / CONFIG_SYS_CLOCK_TICKS_PER_SEC))
2529

2630
#define MAX_TICKS ((k_ticks_t)(UINT32_MAX / CYC_PER_TICK) - 1)

0 commit comments

Comments
 (0)