pm:check the domain in pm_querystate

Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
This commit is contained in:
dulibo1 2023-09-13 16:43:03 +08:00 committed by Xiang Xiao
parent 712734d55b
commit 7a417da65e
1 changed files with 1 additions and 0 deletions

View File

@ -306,6 +306,7 @@ int pm_changestate(int domain, enum pm_state_e newstate)
enum pm_state_e pm_querystate(int domain)
{
DEBUGASSERT(domain >= 0 && domain < CONFIG_PM_NDOMAINS);
return g_pmglobals.domain[domain].state;
}