Do not set 'has_resized' in drmmode_xf86crtc_resize()

The field "has_resized" is used to determine when to trigger a switch
to blit mode during OMAPDRI2ScheduleSwap() (and to implement the swap as
a blit).

In truth, the only time we need to transition from flip to blit is when the
per-CRTC scanouts themselves have been resized or moved, not when the
root framebuffer has resized.

Therefore, rather confusingly, has_resized need not be set during
drmmode_xf86crtc_resize() - it only must be set when one of the per-CRTC
scanouts has changed, as is done in drmmode_update_scanouts().

This saves an unnecessary switch from flip->blit mode when an external
monitor is disconnected.  In such a case, the framebuffer is shrunk, but
the internal CRTC is neither resized nor moved, so no transition to blit
mode is necessary to process the first post-resize flip to the internal

Signed-off-by: Daniel Kurtz <>

TEST=On veyron_pinky, daisy, peach_pi:
  login / logout
  suspend / resume
  plug / unplug HDMI

Change-Id: Id575d7f9d327c492434dded40ebfe745b0b39163
Tested-by: Daniel Kurtz <>
Reviewed-by: St├ęphane Marchesin <>
Commit-Queue: Daniel Kurtz <>
Trybot-Ready: Daniel Kurtz <>
1 file changed