drivers: timer: mcux_gpt: Enable GPT timer to run in doze mode
GPT timer must continue running in low power modes, as it is the system wakeup source. Set configuration to ensure peripheral will not stop running in low power modes. Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
This commit is contained in:
parent
f5ebc30087
commit
59f9dfae58
1 changed files with 4 additions and 0 deletions
|
@ -317,6 +317,10 @@ int sys_clock_driver_init(const struct device *dev)
|
|||
base = (GPT_Type *)DT_REG_ADDR(GPT_INST);
|
||||
|
||||
GPT_GetDefaultConfig(&gpt_config);
|
||||
/* Enable GPT timer to run in SOC low power states */
|
||||
gpt_config.enableRunInStop = true;
|
||||
gpt_config.enableRunInWait = true;
|
||||
gpt_config.enableRunInDoze = true;
|
||||
/* Use 32KHz clock frequency */
|
||||
gpt_config.clockSource = kGPT_ClockSource_LowFreq;
|
||||
gpt_config.enableFreeRun = false; /* Set GPT to reset mode */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue