xorg-server: Changes to 'debian-unstable'
debian/changelog | 2
debian/patches/20-randr-shadow-crashes.diff | 122 ++++++++++++++++++++++++++++
debian/patches/series | 1
3 files changed, 125 insertions(+)
New commits:
commit a08ce4e725887de263cdad2c8e7b20bf54fab336
Author: Julien Cristau <jcristau@debian.org>
Date: Sun Sep 19 22:59:53 2010 +0200
Fixup patch to apply
diff --git a/debian/patches/20-randr-shadow-crashes.diff b/debian/patches/20-randr-shadow-crashes.diff
index 8d58eae..6063b27 100644
--- a/debian/patches/20-randr-shadow-crashes.diff
+++ b/debian/patches/20-randr-shadow-crashes.diff
@@ -50,16 +50,16 @@ diff --git a/hw/xfree86/modes/xf86RandR12.c b/hw/xfree86/modes/xf86RandR12.c
index 043ceee..c17b5fa 100644
--- a/hw/xfree86/modes/xf86RandR12.c
+++ b/hw/xfree86/modes/xf86RandR12.c
-@@ -686,7 +686,7 @@ xf86RandR12ScreenSetSize (ScreenPtr pScreen,
+@@ -687,7 +687,7 @@ xf86RandR12ScreenSetSize (ScreenPtr pScreen,
ScrnInfoPtr pScrn = XF86SCRNINFO(pScreen);
xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(pScrn);
- WindowPtr pRoot = pScreen->root;
+ WindowPtr pRoot = WindowTable[pScreen->myNum];
- PixmapPtr pScrnPix = (*pScreen->GetScreenPixmap)(pScreen);
+ PixmapPtr pScrnPix;
Bool ret = FALSE;
int c;
-@@ -727,6 +727,7 @@ xf86RandR12ScreenSetSize (ScreenPtr pScreen,
+@@ -728,6 +728,7 @@ xf86RandR12ScreenSetSize (ScreenPtr pScreen,
}
}
@@ -104,7 +104,7 @@ diff --git a/hw/xfree86/modes/xf86RandR12.c b/hw/xfree86/modes/xf86RandR12.c
index c17b5fa..b334b3c 100644
--- a/hw/xfree86/modes/xf86RandR12.c
+++ b/hw/xfree86/modes/xf86RandR12.c
-@@ -728,6 +728,13 @@ xf86RandR12ScreenSetSize (ScreenPtr pScreen,
+@@ -729,6 +729,13 @@ xf86RandR12ScreenSetSize (ScreenPtr pScreen,
}
pScrnPix = (*pScreen->GetScreenPixmap)(pScreen);
commit 12d9d4a3e6304de2b1940e6cdb4317412fe807be
Author: Julien Cristau <jcristau@debian.org>
Date: Sun Sep 19 22:53:29 2010 +0200
Don't crash in randr if the driver changes the screen pixmap on resize
diff --git a/debian/changelog b/debian/changelog
index 89bbb67..fe10aca 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,8 @@ xorg-server (2:1.7.7-7) UNRELEASED; urgency=low
* Use linux-any instead of a list of architecture names for restrictions of
build-dependencies (closes: #594927).
+ * Add a couple patches by Chris Wilson to avoid crashing in RandR if the
+ driver changes the screen pixmap on resize.
-- Julien Cristau <jcristau@debian.org> Sun, 12 Sep 2010 21:57:47 +0200
diff --git a/debian/patches/20-randr-shadow-crashes.diff b/debian/patches/20-randr-shadow-crashes.diff
new file mode 100644
index 0000000..8d58eae
--- /dev/null
+++ b/debian/patches/20-randr-shadow-crashes.diff
@@ -0,0 +1,122 @@
+From: Chris Wilson <chris@chris-wilson.co.uk>
+To: xorg-devel@lists.x.org
+Subject: [PATCH 1/3] modes: Beware the driver switching root pixmaps
+Date: Tue, 14 Sep 2010 14:13:39 +0100
+Message-Id: <1284470021-16577-2-git-send-email-chris@chris-wilson.co.uk>
+X-Mailer: git-send-email 1.7.1
+In-Reply-To: <1284470021-16577-1-git-send-email-chris@chris-wilson.co.uk>
+References: <1284470021-16577-1-git-send-email-chris@chris-wilson.co.uk>
+Cc: Julien Cristau <jcristau@debian.org>
+MIME-Version: 1.0
+Content-Type: text/plain; charset="us-ascii"
+Content-Transfer-Encoding: 7bit
+Content-Length: 2264
+
+Program received signal SIGSEGV, Segmentation fault.
+0x080d4a2d in xf86RandR12ScreenSetSize (pScreen=0x8dca3a0, width=800,
+ height=600, mmWidth=210, mmHeight=157)
+ at ../../../../hw/xfree86/modes/xf86RandR12.c:731
+731 ../../../../hw/xfree86/modes/xf86RandR12.c: No such file or directory.
+ in ../../../../hw/xfree86/modes/xf86RandR12.c
+(gdb) bt full
+ height=600, mmWidth=210, mmHeight=157)
+ at ../../../../hw/xfree86/modes/xf86RandR12.c:731
+ randrp = 0x8dcae68
+ pScrn = 0x8dbeb28
+ config = <value optimized out>
+ pRoot = 0x8e08e30
+ pScrnPix = 0xb6d12008
+ ret = 1
+ c = <value optimized out>
+ mmWidth=210, mmHeight=157) at ../../randr/rrscreen.c:185
+No locals.
+ at ../../randr/rrscreen.c:307
+ pWin = 0x8e08e30
+ pScreen = 0x8dca3a0
+ i = <value optimized out>
+ rc = 0
+../../randr/randr.c:485
+
+Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+Cc: Julien Cristau <jcristau@debian.org>
+Tested-by: Julien Cristau <jcristau@debian.org>
+Cc: Keith Packard <keithp@keithp.com>
+Reviewed-by: Keith Packard <keithp@keithp.com>
+---
+ hw/xfree86/modes/xf86RandR12.c | 3 ++-
+ 1 files changed, 2 insertions(+), 1 deletions(-)
+
+diff --git a/hw/xfree86/modes/xf86RandR12.c b/hw/xfree86/modes/xf86RandR12.c
+index 043ceee..c17b5fa 100644
+--- a/hw/xfree86/modes/xf86RandR12.c
++++ b/hw/xfree86/modes/xf86RandR12.c
+@@ -686,7 +686,7 @@ xf86RandR12ScreenSetSize (ScreenPtr pScreen,
+ ScrnInfoPtr pScrn = XF86SCRNINFO(pScreen);
+ xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(pScrn);
+ WindowPtr pRoot = pScreen->root;
+- PixmapPtr pScrnPix = (*pScreen->GetScreenPixmap)(pScreen);
++ PixmapPtr pScrnPix;
+ Bool ret = FALSE;
+ int c;
+
+@@ -727,6 +727,7 @@ xf86RandR12ScreenSetSize (ScreenPtr pScreen,
+ }
+ }
+
++ pScrnPix = (*pScreen->GetScreenPixmap)(pScreen);
+ pScreen->width = pScrnPix->drawable.width = width;
+ pScreen->height = pScrnPix->drawable.height = height;
+ randrp->mmWidth = pScreen->mmWidth = mmWidth;
+--
+1.7.1
+
+From: Chris Wilson <chris@chris-wilson.co.uk>
+To: xorg-devel@lists.x.org
+Subject: [PATCH 2/3] modes: Update pixmapPrivate after driver->resize() calls
+ ModifyPixmapHeader
+Date: Tue, 14 Sep 2010 14:13:40 +0100
+Message-Id: <1284470021-16577-3-git-send-email-chris@chris-wilson.co.uk>
+X-Mailer: git-send-email 1.7.1
+In-Reply-To: <1284470021-16577-1-git-send-email-chris@chris-wilson.co.uk>
+References: <1284470021-16577-1-git-send-email-chris@chris-wilson.co.uk>
+Cc: Julien Cristau <jcristau@debian.org>,
+ Andrew Guertin <lists@dolphinling.net>
+MIME-Version: 1.0
+Content-Type: text/plain; charset="us-ascii"
+Content-Transfer-Encoding: 7bit
+Content-Length: 1542
+
+As with xf86SwitchMode(), if the driver modifies the Screen pixmap header
+in the course of resizing the framebuffer, this change needs to be
+propagated to the ScrnInfo->pixmapPrivate or else the pixmap header will
+be overwritten by xf86EnableDisableFBAccess().
+
+Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
+Cc: Julien Cristau <jcristau@debian.org>
+Cc: Andrew Guertin <lists@dolphinling.net>
+Tested-by: Julien Cristau <jcristau@debian.org>
+Cc: Keith Packard <keithp@keithp.com>
+---
+ hw/xfree86/modes/xf86RandR12.c | 7 +++++++
+ 1 files changed, 7 insertions(+), 0 deletions(-)
+
+diff --git a/hw/xfree86/modes/xf86RandR12.c b/hw/xfree86/modes/xf86RandR12.c
+index c17b5fa..b334b3c 100644
+--- a/hw/xfree86/modes/xf86RandR12.c
++++ b/hw/xfree86/modes/xf86RandR12.c
+@@ -728,6 +728,13 @@ xf86RandR12ScreenSetSize (ScreenPtr pScreen,
+ }
+
+ pScrnPix = (*pScreen->GetScreenPixmap)(pScreen);
++ /*
++ * Get the new Screen pixmap ptr as resize() might have called
++ * ModifyPixmapHeader and xf86EnableDisableFBAccess will put it back...
++ * Unfortunately.
++ */
++ if (pScrnPix->devPrivate.ptr)
++ pScrn->pixmapPrivate = pScrnPix->devPrivate;
+ pScreen->width = pScrnPix->drawable.width = width;
+ pScreen->height = pScrnPix->drawable.height = height;
+ randrp->mmWidth = pScreen->mmWidth = mmWidth;
+--
+1.7.1
diff --git a/debian/patches/series b/debian/patches/series
index 78f1dcd..a175ece 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -18,3 +18,4 @@
17-xfree86-saner-conf-search-paths.diff
18-Add-10-evdev.conf.diff
19-compresize-fix.diff
+20-randr-shadow-crashes.diff
Reply to: