disable crtcs bigger than new screen size during mode switch
When switching modes, we disable CRTCs that do not fit on current freamebuffer, change framebuffer size, then enable required CRTCs in the right locations. This fails in a switch from extended desktop to mirror mode, e.g. from 1366x768+1920x1080 to 1024x768 mirrored. Both CRTCs fit into current framebuffer but they are smaller than the framebuffer we are about to resize to (1024x768) so XRRSetScreenSize(1024,768) call fails because it cannot shrink framebuffer size below size of currently enabled CRTCs. The solution is to disable CRTCs that are bigger than minimum of current and new framebuffer. BUG=chromium:366280 TEST=switch between mirror and extended desktop on Link or Squawks. Screen size\ (in DISPLAY=:0.0 xrandr --verbose) should shrink when switching to mirror mode. R=djkurtz@chromium.org R=oshima@chromium.org Signed-off-by:Dominik Behr <dbehr@chromium.org> Review URL: https://codereview.chromium.org/253513002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@266095 0039d316-1c4b-4281-b951-d872f2087c98
Showing
Please register or sign in to comment