Invoke a padding round in certain use-cases.
* In some use-cases, it is possible that there are
no AppBuffer layers on the external/virtual layer-list
during which all the pipes will be allocated to the
primary. When layers do comeup on external/virtual
layer-list, subsequent overlay sets fail.
* This change ensures that in such cases, we invoke a
padding round on all the displays to free up the
hw resources which can be used in subsequent cycles.
Change-Id: Ifac0b8f51a8719eb55b11010d05b8d11352db054
diff --git a/libhwcomposer/hwc_utils.cpp b/libhwcomposer/hwc_utils.cpp
index d30984b..4ebf685 100644
--- a/libhwcomposer/hwc_utils.cpp
+++ b/libhwcomposer/hwc_utils.cpp
@@ -213,6 +213,10 @@
ctx->dpyAttr[i].mAsHeightRatio = 0;
}
+ for (uint32_t i = 0; i < HWC_NUM_DISPLAY_TYPES; i++) {
+ ctx->mPrevHwLayerCount[i] = 0;
+ }
+
MDPComp::init(ctx);
ctx->mAD = new AssertiveDisplay(ctx);
@@ -897,6 +901,7 @@
if(prevYuvCount != ctx->listStats[dpy].yuvCount) {
ctx->mVideoTransFlag = true;
}
+
if(dpy == HWC_DISPLAY_PRIMARY) {
ctx->mAD->markDoable(ctx, list);
}