xserver: Branch 'master'

Keith Packard keithp at kemper.freedesktop.org
Tue Jun 9 16:24:42 PDT 2009


 hw/xfree86/modes/xf86Crtc.c |    8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

New commits:
commit 6f59a8160042ea145514fdcb410f17f33fd437c2
Author: Benjamin Defnet <benjamin.r.defnet at intel.com>
Date:   Mon Jun 8 21:45:42 2009 -0700

    hw/xf86/modes: Set crtc mode/rotation/transform before calling set_mode_major
    
    This moves code out of each implementation of set_mode_major and back into
    the X server. The real feature here is that the transform is now available
    in the crtc for use by either xf86CrtcRotate or whatever the driver wants to
    do. Without this change, the transform was lost for drivers providing the
    set_mode_major interface.
    
    Note that users of this API will want to stop smashing the transformPresent
    field, and could also stop setting mode/x/y/rotation for new enough X servers,
    but there's no reason to make that change as it will break things when
    running against older X servers.
    
    Signed-off-by: Keith Packard <keithp at keithp.com>
    Acked-by: Daniel Stone <daniel at fooishbar.org>

diff --git a/hw/xfree86/modes/xf86Crtc.c b/hw/xfree86/modes/xf86Crtc.c
index b40e096..585f84d 100644
--- a/hw/xfree86/modes/xf86Crtc.c
+++ b/hw/xfree86/modes/xf86Crtc.c
@@ -266,9 +266,6 @@ xf86CrtcSetModeTransform (xf86CrtcPtr crtc, DisplayModePtr mode, Rotation rotati
     RRTransformRec	saved_transform;
     Bool		saved_transform_present;
 
-    if (crtc->funcs->set_mode_major)
-	return crtc->funcs->set_mode_major(crtc, mode, rotation, x, y);
-
     crtc->enabled = xf86CrtcInUse (crtc);
 
     /* We only hit this if someone explicitly sends a "disabled" modeset. */
@@ -306,6 +303,11 @@ xf86CrtcSetModeTransform (xf86CrtcPtr crtc, DisplayModePtr mode, Rotation rotati
     } else
 	crtc->transformPresent = FALSE;
 
+    if (crtc->funcs->set_mode_major) {
+	ret = crtc->funcs->set_mode_major(crtc, mode, rotation, x, y);
+	goto done;
+    }
+
     /* Pass our mode to the outputs and the CRTC to give them a chance to
      * adjust it according to limitations or output properties, and also
      * a chance to reject the mode entirely.


More information about the xorg-commit mailing list