Skip to content

Commit 4fb6416

Browse files
pixelflingerAndroid (Google) Code Review
authored andcommitted
Merge "we need to guarantee that h/w comp set() is called when a buffer has been retired" into ics-mr0
2 parents fefffc6 + e757a87 commit 4fb6416

File tree

1 file changed

+8
-10
lines changed

1 file changed

+8
-10
lines changed

services/surfaceflinger/SurfaceFlinger.cpp

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -452,7 +452,7 @@ bool SurfaceFlinger::threadLoop()
452452
}
453453

454454
const DisplayHardware& hw(graphicPlane(0).displayHardware());
455-
if (LIKELY(hw.canDraw() && !isFrozen())) {
455+
if (LIKELY(hw.canDraw())) {
456456
// repaint the framebuffer (if needed)
457457

458458
const int index = hw.getCurrentBufferIndex();
@@ -479,15 +479,13 @@ bool SurfaceFlinger::threadLoop()
479479

480480
void SurfaceFlinger::postFramebuffer()
481481
{
482-
if (!mSwapRegion.isEmpty()) {
483-
const DisplayHardware& hw(graphicPlane(0).displayHardware());
484-
const nsecs_t now = systemTime();
485-
mDebugInSwapBuffers = now;
486-
hw.flip(mSwapRegion);
487-
mLastSwapBufferTime = systemTime() - now;
488-
mDebugInSwapBuffers = 0;
489-
mSwapRegion.clear();
490-
}
482+
const DisplayHardware& hw(graphicPlane(0).displayHardware());
483+
const nsecs_t now = systemTime();
484+
mDebugInSwapBuffers = now;
485+
hw.flip(mSwapRegion);
486+
mLastSwapBufferTime = systemTime() - now;
487+
mDebugInSwapBuffers = 0;
488+
mSwapRegion.clear();
491489
}
492490

493491
void SurfaceFlinger::handleConsoleEvents()

0 commit comments

Comments
 (0)