diff --git a/drivers/timer/mcux_os_timer.c b/drivers/timer/mcux_os_timer.c index b20ba462727..18dcb9e5fd2 100644 --- a/drivers/timer/mcux_os_timer.c +++ b/drivers/timer/mcux_os_timer.c @@ -122,9 +122,9 @@ static int sys_clock_driver_init(void) base = (OSTIMER_Type *)DT_INST_REG_ADDR(0); - if (DT_INST_PROP(0, wakeup_source)) { - EnableDeepSleepIRQ(DT_INST_IRQN(0)); - } +#if (DT_INST_PROP(0, wakeup_source)) + EnableDeepSleepIRQ(DT_INST_IRQN(0)); +#endif /* Initialize the OS timer, setting clock configuration. */ OSTIMER_Init(base);