Merge lp:~bkerensa/ubuntu/quantal/xorg-server/quantal-proposed-1104209 into lp:ubuntu/quantal/xorg-server

Proposed by Benjamin Kerensa
Status: Work in progress
Proposed branch: lp:~bkerensa/ubuntu/quantal/xorg-server/quantal-proposed-1104209
Merge into: lp:ubuntu/quantal/xorg-server
Diff against target: 365 lines (+305/-2)
8 files modified
debian/changelog (+25/-0)
debian/patches/233-xf86events-valgrind.patch (+16/-0)
debian/patches/234-composite-borderclip.patch (+48/-0)
debian/patches/235-composite-tracking.diff (+78/-0)
debian/patches/236-use-fbdev-for-poulsbo-oaktrail-medfield.patch (+88/-0)
debian/patches/237-dix-set-the-device-transformation-matrix.patch (+42/-0)
debian/patches/series (+5/-0)
dix/getevents.c (+3/-2)
To merge this branch: bzr merge lp:~bkerensa/ubuntu/quantal/xorg-server/quantal-proposed-1104209
Reviewer Review Type Date Requested Status
Bryce Harrington Needs Fixing
Ubuntu branches Pending
Review via email: mp+144824@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Bryce Harrington (bryce) wrote :

Hi Benjamin, thanks for packaging this patch and preparing the SRU. A few things need fixed though:

1. You applied the patch to the source, but instead it should be put into the debian/patches directory, and the patch name listed in debian/patches/series.

2. For quantal's xserver, our policy is to number patches consecutively. So you need to rename the patch, to 238-dix-fix-zaphod-screen-crossing.patch

3. In the bug report SRU, for regression potential you should elaborate more. Why might it get stuck on the second screen? There's no indication in the upstream bug report that this is possible.

4. You need a test case in the SRU as well. (Should be pretty simple.) Btw, have you reproduced the bug yourself on your own hardware? If so, that will make the SRU easier to verify - otherwise we need to find someone on quantal who can do the verification.

review: Needs Fixing

Unmerged revisions

248. By Benjamin Kerensa

add patch from upstream to fix screen crossings

247. By Timo Aaltonen

[ Maarten Lankhorst ]
* add 233-xf86events-valgrind.patch to fix a xserver corruption
  when acpid is stopped before Xorg is. (LP: #1070481)
* add 235-composite-tracking.diff to fix exa corruption. (LP: #1010794)

[ Bryce Harrington ]
* Add 236-use-fbdev-for-poulsbo-oaktrail-medfield.patch: Never use Intel
  driver on Poulsbo/Oaktrail/Medfield. Thanks to Matthias Klumpp.
  (LP: #1069031)
* Add 237-dix-set-the-device-transformation-matrix.patch: Fix pointer
  jumping with absolute pointing device. Initializes device
  transformation matrix to an identity matrix. Thanks to a7x.
  (LP: #1041063)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/changelog'
2--- debian/changelog 2012-10-08 17:58:54 +0000
3+++ debian/changelog 2013-01-24 22:58:24 +0000
4@@ -1,3 +1,28 @@
5+xorg-server (2:1.13.0-0ubuntu6.2) quantal-proposed; urgency=low
6+
7+ * add 0001-dix-fix-zaphod-screen-scrossing-54654.patch to fix screen
8+ crossings. (LP: #1104209)
9+
10+ -- Benjamin Kerensa <bkerensa@ubuntu.com> Thu, 24 Jan 2013 14:44:02 -0800
11+
12+xorg-server (2:1.13.0-0ubuntu6.1) quantal-proposed; urgency=low
13+
14+ [ Maarten Lankhorst ]
15+ * add 233-xf86events-valgrind.patch to fix a xserver corruption
16+ when acpid is stopped before Xorg is. (LP: #1070481)
17+ * add 235-composite-tracking.diff to fix exa corruption. (LP: #1010794)
18+
19+ [ Bryce Harrington ]
20+ * Add 236-use-fbdev-for-poulsbo-oaktrail-medfield.patch: Never use Intel
21+ driver on Poulsbo/Oaktrail/Medfield. Thanks to Matthias Klumpp.
22+ (LP: #1069031)
23+ * Add 237-dix-set-the-device-transformation-matrix.patch: Fix pointer
24+ jumping with absolute pointing device. Initializes device
25+ transformation matrix to an identity matrix. Thanks to a7x.
26+ (LP: #1041063)
27+
28+ -- Timo Aaltonen <tjaalton@ubuntu.com> Tue, 27 Nov 2012 08:09:59 +0200
29+
30 xorg-server (2:1.13.0-0ubuntu6) quantal; urgency=low
31
32 [ Timo Aaltonen ]
33
34=== added file 'debian/patches/233-xf86events-valgrind.patch'
35--- debian/patches/233-xf86events-valgrind.patch 1970-01-01 00:00:00 +0000
36+++ debian/patches/233-xf86events-valgrind.patch 2013-01-24 22:58:24 +0000
37@@ -0,0 +1,16 @@
38+diff --git a/hw/xfree86/common/xf86Events.c b/hw/xfree86/common/xf86Events.c
39+index 3ad34b5..4bc5f66 100644
40+--- a/hw/xfree86/common/xf86Events.c
41++++ b/hw/xfree86/common/xf86Events.c
42+@@ -271,9 +271,9 @@ xf86Wakeup(pointer blockData, int err, pointer pReadmask)
43+ }
44+
45+ if (err >= 0) { /* we don't want the handlers called if select() */
46+- IHPtr ih; /* returned with an error condition, do we? */
47++ IHPtr ih, ih_tmp; /* returned with an error condition, do we? */
48+
49+- for (ih = InputHandlers; ih; ih = ih->next) {
50++ nt_list_for_each_entry_safe(ih, ih_tmp, InputHandlers, next) {
51+ if (ih->enabled && ih->fd >= 0 && ih->ihproc &&
52+ (FD_ISSET(ih->fd, ((fd_set *) pReadmask)) != 0)) {
53+ ih->ihproc(ih->fd, ih->data);
54
55=== added file 'debian/patches/234-composite-borderclip.patch'
56--- debian/patches/234-composite-borderclip.patch 1970-01-01 00:00:00 +0000
57+++ debian/patches/234-composite-borderclip.patch 2013-01-24 22:58:24 +0000
58@@ -0,0 +1,48 @@
59+compRedirectWindow does not initialize borderClip(X,Y ) members on allocation,
60+which could theoretically cause a crash because borderClip contains a pointer.
61+Solve this by copying the data over from pWin.
62+
63+Noticed this when working on
64+https://bugs.launchpad.net/ubuntu/+source/xorg-server/+bug/1065113
65+
66+Specific error valgrind error I was receiving is:
67+
68+==25858== Conditional jump or move depends on uninitialised value(s)
69+==25858== at 0x1EBF32: compClipNotify (compwindow.c:304)
70+==25858== by 0x2A2C23: miComputeClips (mivaltree.c:489)
71+==25858== by 0x2A321C: miValidateTree (mivaltree.c:695)
72+==25858== by 0x1896EE: MapWindow (window.c:2594)
73+==25858== by 0x1EB15B: compCreateOverlayWindow (compoverlay.c:155)
74+==25858== by 0x1E9ABA: ProcCompositeGetOverlayWindow (compext.c:304)
75+==25858== by 0x15DA50: Dispatch (dispatch.c:428)
76+==25858== by 0x14C569: main (main.c:295)
77+==25858== Uninitialised value was created by a heap allocation
78+==25858== at 0x4C2B3F8: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
79+==25858== by 0x1ED4A3: compRedirectWindow (compalloc.c:172)
80+==25858== by 0x1EC142: compCreateWindow (compwindow.c:558)
81+==25858== by 0x18C56C: CreateWindow (window.c:801)
82+==25858== by 0x1EB0FF: compCreateOverlayWindow (compoverlay.c:145)
83+==25858== by 0x1E9ABA: ProcCompositeGetOverlayWindow (compext.c:304)
84+==25858== by 0x15DA50: Dispatch (dispatch.c:428)
85+==25858== by 0x14C569: main (main.c:295)
86+
87+Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
88+
89+---
90+I'm not 100% sure if this is the correct assignment, I'm just guessing from the functions.
91+
92+diff --git a/composite/compalloc.c b/composite/compalloc.c
93+index cc69c68..b6c5785 100644
94+--- a/composite/compalloc.c
95++++ b/composite/compalloc.c
96+@@ -195,6 +195,8 @@ compRedirectWindow(ClientPtr pClient, WindowPtr pWin, int update)
97+ cw->damaged = FALSE;
98+ cw->pOldPixmap = NullPixmap;
99+ dixSetPrivate(&pWin->devPrivates, CompWindowPrivateKey, cw);
100++ cw->borderClipX = pWin->drawable.x;
101++ cw->borderClipY = pWin->drawable.y;
102+ }
103+ ccw->next = cw->clients;
104+ cw->clients = ccw;
105+
106+
107
108=== added file 'debian/patches/235-composite-tracking.diff'
109--- debian/patches/235-composite-tracking.diff 1970-01-01 00:00:00 +0000
110+++ debian/patches/235-composite-tracking.diff 2013-01-24 22:58:24 +0000
111@@ -0,0 +1,78 @@
112+From: Michel Dänzer <michel.daenzer@amd.com>
113+
114+In particular, make sure pExaScr->src/maskPix are cleared when the
115+corresponding pictures aren't associated with drawables, i.e. solid or gradient
116+pictures. Without this, we would in some cases associate the source/mask region
117+with unrelated pixmaps from previous Composite fallbacks, resulting in random
118+corruption.
119+
120+Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=47266
121+
122+Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
123+---
124+ exa/exa_priv.h | 1 +
125+ exa/exa_unaccel.c | 16 ++++++++++++----
126+ 2 files changed, 13 insertions(+), 4 deletions(-)
127+
128+diff --git a/exa/exa_priv.h b/exa/exa_priv.h
129+index cd6a40b..819feb0 100644
130+--- a/exa/exa_priv.h
131++++ b/exa/exa_priv.h
132+@@ -201,6 +201,7 @@ typedef struct {
133+ RegionRec srcReg;
134+ RegionRec maskReg;
135+ PixmapPtr srcPix;
136++ PixmapPtr maskPix;
137+
138+ } ExaScreenPrivRec, *ExaScreenPrivPtr;
139+
140+diff --git a/exa/exa_unaccel.c b/exa/exa_unaccel.c
141+index 72e59ca..ec49ef0 100644
142+--- a/exa/exa_unaccel.c
143++++ b/exa/exa_unaccel.c
144+@@ -451,6 +451,13 @@ ExaSrcValidate(DrawablePtr pDrawable,
145+ RegionPtr dst;
146+ int xoff, yoff;
147+
148++ if (pExaScr->srcPix == pPix)
149++ dst = &pExaScr->srcReg;
150++ else if (pExaScr->maskPix == pPix)
151++ dst = &pExaScr->maskReg;
152++ else
153++ return;
154++
155+ exaGetDrawableDeltas(pDrawable, pPix, &xoff, &yoff);
156+
157+ box.x1 = x + xoff;
158+@@ -458,8 +465,6 @@ ExaSrcValidate(DrawablePtr pDrawable,
159+ box.x2 = box.x1 + width;
160+ box.y2 = box.y1 + height;
161+
162+- dst = (pExaScr->srcPix == pPix) ? &pExaScr->srcReg : &pExaScr->maskReg;
163+-
164+ RegionInit(&reg, &box, 1);
165+ RegionUnion(dst, dst, &reg);
166+ RegionUninit(&reg);
167+@@ -504,16 +509,19 @@ ExaPrepareCompositeReg(ScreenPtr pScreen,
168+ if (pSrc != pDst)
169+ RegionTranslate(pSrc->pCompositeClip,
170+ -pSrc->pDrawable->x, -pSrc->pDrawable->y);
171+- }
172++ } else
173++ pExaScr->srcPix = NULL;
174+
175+ if (pMask && pMask->pDrawable) {
176+ pMaskPix = exaGetDrawablePixmap(pMask->pDrawable);
177+ RegionNull(&pExaScr->maskReg);
178+ maskReg = &pExaScr->maskReg;
179++ pExaScr->maskPix = pMaskPix;
180+ if (pMask != pDst && pMask != pSrc)
181+ RegionTranslate(pMask->pCompositeClip,
182+ -pMask->pDrawable->x, -pMask->pDrawable->y);
183+- }
184++ } else
185++ pExaScr->maskPix = NULL;
186+
187+ RegionTranslate(pDst->pCompositeClip,
188+ -pDst->pDrawable->x, -pDst->pDrawable->y);
189+-- 1.7.10.4
190
191=== added file 'debian/patches/236-use-fbdev-for-poulsbo-oaktrail-medfield.patch'
192--- debian/patches/236-use-fbdev-for-poulsbo-oaktrail-medfield.patch 1970-01-01 00:00:00 +0000
193+++ debian/patches/236-use-fbdev-for-poulsbo-oaktrail-medfield.patch 2013-01-24 22:58:24 +0000
194@@ -0,0 +1,88 @@
195+From ec3ce5493ec00ca0a9304b705a58a40e364f88fb Mon Sep 17 00:00:00 2001
196+From: Stefan Dirsch <sndirsch@suse.de>
197+Date: Sun, 22 Jul 2012 12:29:51 +0200
198+Subject: [PATCH 3/3] Do not use intel driver on Poulsbo, Oaktrail, Medfield, CDV.
199+
200+IDs stolen from Kernel psb driver.
201+---
202+ hw/xfree86/common/xf86pciBus.c | 64 +++++++++++++++++++++++++++++++++++-----
203+ 1 files changed, 56 insertions(+), 8 deletions(-)
204+
205+diff --git a/hw/xfree86/common/xf86pciBus.c b/hw/xfree86/common/xf86pciBus.c
206+index a2c18eb..258988a 100644
207+--- a/hw/xfree86/common/xf86pciBus.c
208++++ b/hw/xfree86/common/xf86pciBus.c
209+@@ -1147,14 +1147,62 @@ xf86VideoPtrToDriverList(struct pci_device *dev,
210+ driverList[0] = "i128";
211+ break;
212+ case 0x8086:
213+- if ((dev->device_id == 0x00d1) || (dev->device_id == 0x7800)) {
214+- driverList[0] = "i740";
215+- }
216+- else if (dev->device_id == 0x8108) {
217+- break; /* "hooray" for poulsbo */
218+- }
219+- else {
220+- driverList[0] = "intel";
221++ switch (dev->device_id)
222++ {
223++ /* Intel i740 */
224++ case 0x00d1:
225++ case 0x7800:
226++ driverList[0] = "i740";
227++ break;
228++ /* GMA500/Poulsbo */
229++ case 0x8108:
230++ case 0x8109:
231++ /* Try psb driver on Poulsbo - if available */
232++ driverList[0] = "psb";
233++ driverList[1] = "psb_drv";
234++ break;
235++ /* GMA600/Oaktrail */
236++ case 0x4100:
237++ case 0x4101:
238++ case 0x4102:
239++ case 0x4103:
240++ case 0x4104:
241++ case 0x4105:
242++ case 0x4106:
243++ case 0x4107:
244++ /* Atom E620/Oaktrail */
245++ case 0x4108:
246++ /* Medfield */
247++ case 0x0130:
248++ case 0x0131:
249++ case 0x0132:
250++ case 0x0133:
251++ case 0x0134:
252++ case 0x0135:
253++ case 0x0136:
254++ case 0x0137:
255++ /* GMA 3600/CDV */
256++ case 0x0be0:
257++ case 0x0be1:
258++ case 0x0be2:
259++ case 0x0be3:
260++ case 0x0be4:
261++ case 0x0be5:
262++ case 0x0be6:
263++ case 0x0be7:
264++ case 0x0be8:
265++ case 0x0be9:
266++ case 0x0bea:
267++ case 0x0beb:
268++ case 0x0bec:
269++ case 0x0bed:
270++ case 0x0bee:
271++ case 0x0bef:
272++ /* Use fbdev/vesa driver on Oaktrail, Medfield, CDV */
273++ break;
274++ default:
275++ driverList[0] = "intel";
276++ break;
277+ }
278+ break;
279+ case 0x102b:
280+--
281+1.7.3.4
282+
283
284=== added file 'debian/patches/237-dix-set-the-device-transformation-matrix.patch'
285--- debian/patches/237-dix-set-the-device-transformation-matrix.patch 1970-01-01 00:00:00 +0000
286+++ debian/patches/237-dix-set-the-device-transformation-matrix.patch 2013-01-24 22:58:24 +0000
287@@ -0,0 +1,42 @@
288+From 3d1051aecbb1955084804133cacd12c7f696833a Mon Sep 17 00:00:00 2001
289+From: Peter Hutterer <peter.hutterer@who-t.net>
290+Date: Thu, 20 Sep 2012 05:56:39 +1000
291+Subject: [PATCH] dix: set the device transformation matrix
292+
293+The property handler is registered after setting the property, so
294+dev->transform remains as all-zeros. That causes pixman_f_transform_invert()
295+to fail (in transformAbsolute()) and invert remains as garbage. This
296+may then cause a cursor jump to 0,0.
297+
298+Since the axes are not yet initialized here and we need to allow for drivers
299+changing the matrix, we cannot use the property handler for matrix
300+initialization, essentially duplicating the code.
301+
302+Triggered by the fix to (#49347) in 749a593e49adccdf1225be28a521412ec85333f4
303+
304+https://bugzilla.redhat.com/show_bug.cgi?id=852841
305+
306+Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
307+Reviewed-by: Chase Douglas <chase.douglas@ubuntu.com>
308+Signed-off-by: Keith Packard <keithp@keithp.com>
309+---
310+ dix/devices.c | 3 +++
311+ 1 file changed, 3 insertions(+)
312+
313+diff --git a/dix/devices.c b/dix/devices.c
314+index 9cf04ed..66d4406 100644
315+--- a/dix/devices.c
316++++ b/dix/devices.c
317+@@ -306,6 +306,9 @@ AddInputDevice(ClientPtr client, DeviceProc deviceProc, Bool autoStart)
318+ /* unity matrix */
319+ memset(transform, 0, sizeof(transform));
320+ transform[0] = transform[4] = transform[8] = 1.0f;
321++ dev->transform.m[0][0] = 1.0;
322++ dev->transform.m[1][1] = 1.0;
323++ dev->transform.m[2][2] = 1.0;
324+
325+ XIChangeDeviceProperty(dev, XIGetKnownProperty(XI_PROP_TRANSFORM),
326+ XIGetKnownProperty(XATOM_FLOAT), 32,
327+--
328+1.7.11.3
329+
330
331=== modified file 'debian/patches/series'
332--- debian/patches/series 2012-10-08 17:58:54 +0000
333+++ debian/patches/series 2013-01-24 22:58:24 +0000
334@@ -23,6 +23,10 @@
335 208_switch_on_release.diff
336 227_null_ptr_midispcur.patch
337 232-xf86compatoutput-valgrind.patch
338+233-xf86events-valgrind.patch
339+#234-composite-borderclip.patch
340+235-composite-tracking.diff
341+236-use-fbdev-for-poulsbo-oaktrail-medfield.patch
342
343 ## waiting for review by upstream
344 111_armel-drv-fallbacks.patch
345@@ -32,3 +36,4 @@
346 229_udev-fix.diff
347 230-fix-compat-output-selection.patch
348 231-scan-pci-after-probing-devices.patch
349+237-dix-set-the-device-transformation-matrix.patch
350
351=== modified file 'dix/getevents.c'
352--- dix/getevents.c 2012-09-06 12:25:51 +0000
353+++ dix/getevents.c 2013-01-24 22:58:24 +0000
354@@ -1400,8 +1400,9 @@
355 coordinates were.
356 */
357 if (flags & POINTER_SCREEN) {
358- screenx = sx;
359- screeny = sy;
360+ scr = miPointerGetScreen(pDev);
361+ screenx = sx + scr->x;
362+ screeny = sy + scr->y;
363 }
364
365 scr = positionSprite(pDev, (flags & POINTER_ABSOLUTE) ? Absolute : Relative,

Subscribers

People subscribed via source and target branches