diff options
-rwxr-xr-x | sdm/libs/core/display_base.cpp | 12 | ||||
-rw-r--r-- | sdm/libs/core/display_builtin.cpp | 2 |
2 files changed, 8 insertions, 6 deletions
diff --git a/sdm/libs/core/display_base.cpp b/sdm/libs/core/display_base.cpp index cc2855e1..f1025bbd 100755 --- a/sdm/libs/core/display_base.cpp +++ b/sdm/libs/core/display_base.cpp @@ -625,16 +625,18 @@ DisplayError DisplayBase::SetDisplayState(DisplayState state, bool teardown, DisablePartialUpdateOneFrame(); if (error == kErrorNone) { - if (!pending_doze_ && !pending_power_on_) { - active_ = active; - state_ = state; - } - comp_manager_->SetDisplayState(display_comp_ctx_, state, release_fence ? *release_fence : -1); // If previously requested doze state is still pending reset it on any new display state request // and handle the new request. if (state != kStateDoze) { pending_doze_ = false; } + + if (!pending_doze_ && !pending_power_on_) { + active_ = active; + state_ = state; + } + comp_manager_->SetDisplayState(display_comp_ctx_, state, release_fence ? *release_fence : -1); + // If previously requested power on state is still pending reset it on any new display state // request and handle the new request. if (state != kStateOn) { diff --git a/sdm/libs/core/display_builtin.cpp b/sdm/libs/core/display_builtin.cpp index 4cdf9d83..2e0538a4 100644 --- a/sdm/libs/core/display_builtin.cpp +++ b/sdm/libs/core/display_builtin.cpp @@ -332,7 +332,7 @@ DisplayError DisplayBuiltIn::SetDisplayMode(uint32_t mode) { HWDisplayMode hw_display_mode = static_cast<HWDisplayMode>(mode); uint32_t pending = 0; - if (!active_) { + if (!active_ && !pending_doze_ && !pending_power_on_) { DLOGW("Invalid display state = %d. Panel must be on.", state_); return kErrorNotSupported; } |