PM: domains: Fix handling of unavailable/disabled idle states
authorSudeep Holla <sudeep.holla@arm.com>
Tue, 25 Oct 2022 12:34:32 +0000 (13:34 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 3 Nov 2022 14:59:18 +0000 (23:59 +0900)
commiteb59cb2fabd4df3efc40c912a9eeff2b9360d181
treeda7ca309fe0a6d787a8a998c8468b1b0f0c0f14c
parentbde7c2acef304b190463c95ae9da027b275261a2
PM: domains: Fix handling of unavailable/disabled idle states

[ Upstream commit e0c57a5c70c13317238cb19a7ded0eab4a5f7de5 ]

Platforms can provide the information about the availability of each
idle states via status flag. Platforms may have to disable one or more
idle states for various reasons like broken firmware or other unmet
dependencies.

Fix handling of such unavailable/disabled idle states by ignoring them
while parsing the states.

Fixes: a3381e3a65cb ("PM / domains: Fix up domain-idle-states OF parsing")
Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/base/power/domain.c