Change the LPM locks API:

Instead of using a separate data structure to request that a PD remain powered during deep sleep,
we do the same within the main LPM data structure through an additional field.

This allows us to maintain only one linked list of LPM modules and overall improves code clarity
This commit is contained in:
George Oikonomou 2015-05-01 16:42:03 +01:00
parent b3ac3ac0c1
commit 421fbfae25
9 changed files with 38 additions and 96 deletions

View file

@ -64,9 +64,6 @@ static unsigned long irq_energest = 0;
/*---------------------------------------------------------------------------*/
LIST(modules_list);
/*---------------------------------------------------------------------------*/
/* Control what power domains we are allow to run under what mode */
LIST(power_domain_locks_list);
/* PDs that may stay on in deep sleep */
#define LOCKABLE_DOMAINS ((uint32_t)(PRCM_DOMAIN_SERIAL | PRCM_DOMAIN_PERIPH))
/*---------------------------------------------------------------------------*/
@ -399,7 +396,6 @@ void
lpm_init()
{
list_init(modules_list);
list_init(power_domain_locks_list);
}
/*---------------------------------------------------------------------------*/
void