timer: nxp: Update OS-Timer to use wakeup-source flag
Enable the OS Timer to be a wakeup source only if configured through device tree property. Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
This commit is contained in:
parent
58afbc8f26
commit
d13ffceb62
1 changed files with 3 additions and 1 deletions
|
@ -123,7 +123,9 @@ static int sys_clock_driver_init(const struct device *dev)
|
||||||
|
|
||||||
base = (OSTIMER_Type *)DT_INST_REG_ADDR(0);
|
base = (OSTIMER_Type *)DT_INST_REG_ADDR(0);
|
||||||
|
|
||||||
EnableDeepSleepIRQ(DT_INST_IRQN(0));
|
if (DT_INST_PROP(0, wakeup_source)) {
|
||||||
|
EnableDeepSleepIRQ(DT_INST_IRQN(0));
|
||||||
|
}
|
||||||
|
|
||||||
/* Initialize the OS timer, setting clock configuration. */
|
/* Initialize the OS timer, setting clock configuration. */
|
||||||
OSTIMER_Init(base);
|
OSTIMER_Init(base);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue