summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVenkat Thogaru <vthogaru@codeaurora.org>2019-06-03 16:16:42 +0530
committerVenkat Thogaru <vthogaru@codeaurora.org>2020-01-22 11:17:38 +0530
commit3f77edd72dfdaa2b0595596fb9db6c5a95931abe (patch)
tree885de0ac6cb0db39d8752557c5372187d6ff685d
parent173ecd2e0743ab9529fadcf998ec13254bf45105 (diff)
downloaddisplay-3f77edd72dfdaa2b0595596fb9db6c5a95931abe.tar.gz
sdm: Disable idle power collapse if hdr present
Luts re-programming after idle power collpase taking more than one vsync some times causing flickering. Hence disable idle power collapse during this time. CRs-Fixed: 2432683 Change-Id: Iceb4d63d00e9b53ae01924d6c16d38505f546e96
-rw-r--r--sdm/libs/hwc2/hwc_display_builtin.cpp7
-rw-r--r--sdm/libs/hwc2/hwc_display_builtin.h3
2 files changed, 8 insertions, 2 deletions
diff --git a/sdm/libs/hwc2/hwc_display_builtin.cpp b/sdm/libs/hwc2/hwc_display_builtin.cpp
index 5aaa5316..199e0b04 100644
--- a/sdm/libs/hwc2/hwc_display_builtin.cpp
+++ b/sdm/libs/hwc2/hwc_display_builtin.cpp
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2014-2019, The Linux Foundation. All rights reserved.
+* Copyright (c) 2014-2020, The Linux Foundation. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
@@ -229,6 +229,11 @@ HWC2::Error HWCDisplayBuiltIn::Validate(uint32_t *out_num_types, uint32_t *out_n
layer_stack_.flags.post_processed_output = post_processed_output_;
}
}
+ // Todo: relook this case
+ if (layer_stack_.flags.hdr_present != hdr_present_) {
+ error = display_intf_->ControlIdlePowerCollapse(!layer_stack_.flags.hdr_present, true);
+ hdr_present_ = layer_stack_.flags.hdr_present;
+ }
uint32_t num_updating_layers = GetUpdatingLayersCount();
bool one_updating_layer = (num_updating_layers == 1);
diff --git a/sdm/libs/hwc2/hwc_display_builtin.h b/sdm/libs/hwc2/hwc_display_builtin.h
index 071e1d45..4de6853a 100644
--- a/sdm/libs/hwc2/hwc_display_builtin.h
+++ b/sdm/libs/hwc2/hwc_display_builtin.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014-2019, The Linux Foundation. All rights reserved.
+ * Copyright (c) 2014-2020, The Linux Foundation. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
@@ -143,6 +143,7 @@ class HWCDisplayBuiltIn : public HWCDisplay {
int default_mode_status_ = 0;
bool pending_refresh_ = true;
bool enable_drop_refresh_ = false;
+ bool hdr_present_ = false;
// Members for 1 frame capture in a client provided buffer
bool frame_capture_buffer_queued_ = false;