summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKeith Packard <keithp@neko.keithp.com>2007-03-23 14:39:10 -0700
committerKeith Packard <keithp@neko.keithp.com>2007-03-23 14:39:49 -0700
commit36e5227215e0912ddf8a010db042467f00efe0fc (patch)
treeb1dd84316b5bd7927de1aa7fd3a8fc7b82559169
parent945aa0aa556429b50dea8e8ebc0008304b093eb7 (diff)
Ensure that crtc desired values track most recent mode.
desiredX and desiredY were not recorded during xf86InitialConfiguration. desiredX, desiredY and desiredRotation were not recorded during xf86SetSingleMode.
-rw-r--r--hw/xfree86/modes/xf86Crtc.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/hw/xfree86/modes/xf86Crtc.c b/hw/xfree86/modes/xf86Crtc.c
index 2341715e7..b9895d9da 100644
--- a/hw/xfree86/modes/xf86Crtc.c
+++ b/hw/xfree86/modes/xf86Crtc.c
@@ -1589,6 +1589,8 @@ xf86InitialConfiguration (ScrnInfoPtr scrn, Bool canGrow)
{
crtc->desiredMode = *mode;
crtc->desiredRotation = output->initial_rotation;
+ crtc->desiredX = output->initial_x;
+ crtc->desiredY = output->initial_y;
crtc->enabled = TRUE;
crtc->x = output->initial_x;
crtc->y = output->initial_y;
@@ -1813,7 +1815,12 @@ xf86SetSingleMode (ScrnInfoPtr pScrn, DisplayModePtr desired, Rotation rotation)
if (!xf86CrtcSetMode (crtc, crtc_mode, rotation, 0, 0))
ok = FALSE;
else
+ {
crtc->desiredMode = *crtc_mode;
+ crtc->desiredRotation = rotation;
+ crtc->desiredX = 0;
+ crtc->desiredY = 0;
+ }
}
xf86DisableUnusedFunctions(pScrn);
return ok;