File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -96,6 +96,9 @@ static void uart_stm32_pm_policy_state_lock_get(const struct device *dev)
96
96
if (!data -> pm_policy_state_on ) {
97
97
data -> pm_policy_state_on = true;
98
98
pm_policy_state_lock_get (PM_STATE_SUSPEND_TO_IDLE , PM_ALL_SUBSTATES );
99
+ if (IS_ENABLED (CONFIG_PM_S2RAM )) {
100
+ pm_policy_state_lock_get (PM_STATE_SUSPEND_TO_RAM , PM_ALL_SUBSTATES );
101
+ }
99
102
}
100
103
}
101
104
@@ -106,6 +109,9 @@ static void uart_stm32_pm_policy_state_lock_put(const struct device *dev)
106
109
if (data -> pm_policy_state_on ) {
107
110
data -> pm_policy_state_on = false;
108
111
pm_policy_state_lock_put (PM_STATE_SUSPEND_TO_IDLE , PM_ALL_SUBSTATES );
112
+ if (IS_ENABLED (CONFIG_PM_S2RAM )) {
113
+ pm_policy_state_lock_put (PM_STATE_SUSPEND_TO_RAM , PM_ALL_SUBSTATES );
114
+ }
109
115
}
110
116
}
111
117
#endif /* CONFIG_PM */
You can’t perform that action at this time.
0 commit comments