pm: device: Change atomic flags type

Just using a simple atomic for flags instead of using an array.

While is neat using ATOMIC_DEFINE for future proof. The reality is
that it brings some problem for the wakeup source implementation
that needs to statically initialize it during the device definition.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
This commit is contained in:
Flavio Ceolin 2021-07-31 16:17:29 -07:00 committed by Christopher Friedt
commit a245ed2a87
2 changed files with 5 additions and 5 deletions

View file

@ -96,7 +96,7 @@ struct pm_device {
/** Device pm enable flag */
bool enable : 1;
/* Device PM status flags. */
ATOMIC_DEFINE(flags, PM_DEVICE_FLAG_COUNT);
atomic_t flags;
/** Device usage count */
uint32_t usage;
/** Device power state */