subsys: power: Add OS managed Power Management framework
Add support for OS managed Power Management framework for Zephyr under 'subsys/power'. This framework takes care of implementing the _sys_soc_suspend/_sys_soc_resume API's, a PM policy based on SoC Low Power residencies and also provides necessary API's to do devices suspend and resume. Also add necessary changes to support the existing Application managed Power Management framework. Signed-off-by: Ramakrishna Pallala <ramakrishna.pallala@intel.com>
This commit is contained in:
parent
1301cc636b
commit
2ad647857c
9 changed files with 496 additions and 0 deletions
88
subsys/power/Kconfig
Normal file
88
subsys/power/Kconfig
Normal file
|
@ -0,0 +1,88 @@
|
|||
|
||||
if PM_CONTROL_OS
|
||||
menu "OS Power Management"
|
||||
|
||||
if SYS_POWER_LOW_POWER_STATE
|
||||
config PM_CONTROL_OS_LPS
|
||||
bool "Platform supports LPS"
|
||||
help
|
||||
Select this option if SoC support LPS state.
|
||||
|
||||
if PM_CONTROL_OS_LPS
|
||||
config PM_LPS_MIN_RES
|
||||
int "LPS minimum residency"
|
||||
default 5
|
||||
help
|
||||
Minimum residency in ticks to enter LPS state.
|
||||
endif
|
||||
|
||||
config PM_CONTROL_OS_LPS_1
|
||||
bool "Platform supports LPS_1"
|
||||
help
|
||||
Select this option if SoC support LPS_1 state.
|
||||
|
||||
if PM_CONTROL_OS_LPS_1
|
||||
config PM_LPS_1_MIN_RES
|
||||
int "LPS_1 minimum residency"
|
||||
default 10
|
||||
help
|
||||
Minimum residency in ticks to enter LPS_1 state.
|
||||
endif
|
||||
|
||||
config PM_CONTROL_OS_LPS_2
|
||||
bool "Platform supports LPS_2"
|
||||
help
|
||||
Select this option if SoC support LPS_2 state.
|
||||
|
||||
if PM_CONTROL_OS_LPS_2
|
||||
config PM_LPS_2_MIN_RES
|
||||
int "LPS_2 minimum residency"
|
||||
default 30
|
||||
help
|
||||
Minimum residency in ticks to enter LPS_2 state.
|
||||
endif
|
||||
endif # SYS_POWER_LOW_POWER_STATE
|
||||
|
||||
if SYS_POWER_DEEP_SLEEP
|
||||
config PM_CONTROL_OS_DEEP_SLEEP
|
||||
bool "Platform supports DEEP_SLEEP"
|
||||
help
|
||||
Select this option if SoC support DEEP_SLEEP state.
|
||||
|
||||
if PM_CONTROL_OS_DEEP_SLEEP
|
||||
config PM_DEEP_SLEEP_MIN_RES
|
||||
int "DEEP_SLEEP minimum residency"
|
||||
default 60
|
||||
help
|
||||
Minimum residency in ticks to enter DEEP_SLEEP state.
|
||||
endif
|
||||
|
||||
config PM_CONTROL_OS_DEEP_SLEEP_1
|
||||
bool "Platform supports DEEP_SLEEP_1"
|
||||
help
|
||||
Select this option if SoC support DEEP_SLEEP_1 state.
|
||||
|
||||
if PM_CONTROL_OS_DEEP_SLEEP_1
|
||||
config PM_DEEP_SLEEP_1_MIN_RES
|
||||
int "DEEP_SLEEP_1 minimum residency"
|
||||
default 90
|
||||
help
|
||||
Minimum residency in ticks to enter DEEP_SLEEP_1 state.
|
||||
endif
|
||||
|
||||
config PM_CONTROL_OS_DEEP_SLEEP_2
|
||||
bool "Platform supports DEEP_SLEEP_2"
|
||||
help
|
||||
Select this option if SoC support DEEP_SLEEP_2 state.
|
||||
|
||||
if PM_CONTROL_OS_DEEP_SLEEP_2
|
||||
config PM_DEEP_SLEEP_2_MIN_RES
|
||||
int "DEEP_SLEEP_2 minimum residency"
|
||||
default 120
|
||||
help
|
||||
Minimum residency in ticks to enter DEEP_SLEEP_2 state.
|
||||
endif
|
||||
endif # PM_CONTROL_OS_DEEP_SLEEP
|
||||
|
||||
endmenu
|
||||
endif # PM_CONTROL_OS
|
Loading…
Add table
Add a link
Reference in a new issue