[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

xorg-server: Changes to 'debian-unstable'



 debian/changelog              |    3 +++
 hw/xfree86/common/xf86RandR.c |   19 +++++++++++++++++++
 2 files changed, 22 insertions(+)

New commits:
commit ff06e49d2b6df84e9dbc4de6f238615ae01cfb16
Author: Julien Cristau <jcristau@debian.org>
Date:   Sat Aug 2 21:08:20 2008 +0200

    changelog update

diff --git a/debian/changelog b/debian/changelog
index 13b1be9..bc2f74a 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -8,6 +8,9 @@ xorg-server (2:1.4.2-3) UNRELEASED; urgency=low
     - Xi: ChangeDeviceControl presence events should set the appropriate
       devchange
     - Fix potential crasher in xf86CrtcRotate()
+  * Cherry-picked from 1.5:
+    - Work around the DIX losing mmWidth/mmHeight for RandR 1.1 DDXen
+      (closes: #491526).
 
  -- Julien Cristau <jcristau@debian.org>  Fri, 18 Jul 2008 17:00:16 +0200
 

commit eceb40ce485ce17b9a27731c35d05c45d5c24f76
Author: Aaron Plattner <aplattner@nvidia.com>
Date:   Mon Jun 30 17:29:35 2008 -0700

    Work around the DIX losing mmWidth/mmHeight for RandR 1.1 DDXen.
    
    RandR 1.1 has a physical size for each mode.  It used to be that the DIX would
    remember these modes and pass them back up to the DDX when changing the screen
    configuration.  The DDX uses RR_GET_MODE_MM to query the driver for the physical
    dimensions of the screen, allowing it to preserve the DPI.
    
    With RandR 1.2, the physical dimensions are stored as part of the output, rather
    than per mode.  The DIX only uses the sizes passed in from the DDX to select the
    mode pool for the "default" output, and forgets the physical sizes.  Then, when
    reconfiguring the screen, it makes up a new RRScreenSizeRec using the dimensions
    from the output, screwing up the DPI.
    
    This change works around this problem by ignoring the DIX and querying the real
    size from the driver.
    (cherry picked from commit 2e8daee05343b2853b677acf4554def0ceeada00)
    (cherry picked from commit 75b5e999f045524e2b362e848a0104e1a4217061)

diff --git a/hw/xfree86/common/xf86RandR.c b/hw/xfree86/common/xf86RandR.c
index 288d721..95c4b95 100644
--- a/hw/xfree86/common/xf86RandR.c
+++ b/hw/xfree86/common/xf86RandR.c
@@ -171,6 +171,25 @@ xf86RandRSetMode (ScreenPtr	    pScreen,
 	scrp->virtualX = mode->HDisplay;
 	scrp->virtualY = mode->VDisplay;
     }
+
+    /*
+     * The DIX forgets the physical dimensions we passed into RRRegisterSize, so
+     * reconstruct them if possible.
+     */
+    if(scrp->DriverFunc) {
+	xorgRRModeMM RRModeMM;
+
+	RRModeMM.mode = mode;
+	RRModeMM.virtX = scrp->virtualX;
+	RRModeMM.virtY = scrp->virtualY;
+	RRModeMM.mmWidth = mmWidth;
+	RRModeMM.mmHeight = mmHeight;
+
+	(*scrp->DriverFunc)(scrp, RR_GET_MODE_MM, &RRModeMM);
+
+	mmWidth = RRModeMM.mmWidth;
+	mmHeight = RRModeMM.mmHeight;
+    }
     if(randrp->rotation & (RR_Rotate_90 | RR_Rotate_270))
     {
 	/* If the screen is rotated 90 or 270 degrees, swap the sizes. */


Reply to: