drivers/power/pm_initialize.c: Fix pm_domain_s.stime unint caused time error. Bug deatil:
1. open CONFIG_DEBUG_FEATURES CONFIG_SYSTEM_TIME64 CONFIG_CLOCK_MONOTONIC ==> INITIAL_SYSTEM_TIMER_TICKS very big data, not zero 2. close CONFIG_SCHED_TICKLESS ==> use g_system_timer as system clock 3. pm_domain_s.stime init to zero 4. clock_systimer() - pm_domain_s.stime get big data, error
This commit is contained in:
parent
68a115aed9
commit
f4a3541d26
|
@ -89,6 +89,16 @@ struct pm_global_s g_pmglobals =
|
|||
|
||||
void pm_initialize(void)
|
||||
{
|
||||
FAR struct pm_domain_s *pdom;
|
||||
int i;
|
||||
|
||||
/* Init saved time slice */
|
||||
|
||||
for (i = 0; i < CONFIG_PM_NDOMAINS; i++)
|
||||
{
|
||||
pdom = &g_pmglobals.domain[i];
|
||||
pdom->stime = clock_systimer();
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* CONFIG_PM */
|
||||
|
|
Loading…
Reference in New Issue