From b5e1336e83436d7eaef4a4dbb3343acf40decb1e Mon Sep 17 00:00:00 2001 From: Flavio Ceolin Date: Tue, 23 Feb 2021 13:05:58 -0800 Subject: [PATCH] power: s/POWER_STATE_ACTIVE/PM_STATE_ACTIVE Fix some references to old power state names. Signed-off-by: Flavio Ceolin --- include/power/power.h | 2 +- kernel/idle.c | 2 +- tests/subsys/power/power_mgmt/src/main.c | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/include/power/power.h b/include/power/power.h index c5f20c1472b..c518ac80d0f 100644 --- a/include/power/power.h +++ b/include/power/power.h @@ -228,7 +228,7 @@ void pm_system_resume_from_deep_sleep(void); * * This function would notify exit from kernel idling if a corresponding * pm_system_suspend() notification was handled and did not return - * POWER_STATE_ACTIVE. + * PM_STATE_ACTIVE. * * This function would be called from the ISR context of the event * that caused the exit from kernel idling. This will be called immediately diff --git a/kernel/idle.c b/kernel/idle.c index 9b7d3bb89f7..e6151e7c99f 100644 --- a/kernel/idle.c +++ b/kernel/idle.c @@ -56,7 +56,7 @@ static void pm_save_idle(void) /* * Call the suspend hook function of the soc interface to allow * entry into a low power state. The function returns - * POWER_STATE_ACTIVE if low power state was not entered, in which + * PM_STATE_ACTIVE if low power state was not entered, in which * case, kernel does normal idle processing. * * This function is entered with interrupts disabled. If a low power diff --git a/tests/subsys/power/power_mgmt/src/main.c b/tests/subsys/power/power_mgmt/src/main.c index c60e08aba6c..9cf8488e6c2 100644 --- a/tests/subsys/power/power_mgmt/src/main.c +++ b/tests/subsys/power/power_mgmt/src/main.c @@ -45,7 +45,7 @@ __weak void pm_power_state_set(struct pm_state_info info) zassert_false(device_power_state == DEVICE_PM_ACTIVE_STATE, NULL); /* this function is called when system entering low power state, so - * parameter state should not be POWER_STATE_ACTIVE + * parameter state should not be PM_STATE_ACTIVE */ zassert_false(info.state == PM_STATE_ACTIVE, "Entering low power state with a wrong parameter"); @@ -131,7 +131,7 @@ static void notify_pm_state_exit(enum pm_state state) * - The idle routine provide a timeout parameter to the suspend routine * indicating the amount of time guaranteed to expire before the next * timeout, pm_policy_next_state() handle this parameter. - * - In this case, pm_policy_next_sate() return POWER_STATE_ACTIVE, + * - In this case, pm_policy_next_sate() return PM_STATE_ACTIVE, * so there is no low power operation happen. * * @see pm_policy_next_state()