Samsung / TizenRT

TizenRT is a lightweight RTOS-based platform to support low-end IoT devices
Apache License 2.0
561 stars 560 forks source link

pm: Change to not check CONFIG_PM when using pm apis in other modules #6270

Closed ewoodev closed 1 week ago

ewoodev commented 1 week ago

The PM API can be used in many places. So, It is difficult to check CONFIG_PM in all codes. Therefore, even if CONFIG_PM is disabled, we change it so that the API can be provided as follows.

  1. the PM driver is always enabled,
  2. when CONFIG_PM is disabled, pm_sleep(milliseconds) is replaced with usleep(milliseconds * USEC_PER_MSEC).
  3. The remaining APIs return OK without any action.