Check that wanted sleep state is supported by powerdomain. If it is
not supported, then use next lowest supported state.
Check also on suspend that state of pwrdm was lower or equal.
Signed-off-by: Jouni Hogander <jouni.hogander@nokia.com>
Acked-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>