[oe-commits] David-John Willis : xf86-input-tslib 0.0.6: Add patch for XOrg 1.7. 4 to fix crashes on XGetPointerControl request.

git version control git at git.openembedded.org
Tue Feb 9 20:10:55 UTC 2010


Module: openembedded.git
Branch: shr/unstable
Commit: f7e121d58819a1566d063f82668819f10f5a66d7
URL:    http://gitweb.openembedded.net/?p=openembedded.git&a=commit;h=f7e121d58819a1566d063f82668819f10f5a66d7

Author: David-John Willis <John.Willis at Distant-earth.com>
Date:   Tue Feb  9 12:08:01 2010 +0000

xf86-input-tslib 0.0.6: Add patch for XOrg 1.7.4 to fix crashes on XGetPointerControl request.

* From Grazvydas Ignotas - Already pushed to mainline for next xf86-input-tslib release.

---

 .../xserver-174-XGetPointerControl.patch           |   34 ++++++++++++++++++++
 recipes/xorg-driver/xf86-input-tslib_0.0.6.bb      |    8 +++--
 2 files changed, 39 insertions(+), 3 deletions(-)

diff --git a/recipes/xorg-driver/xf86-input-tslib/xserver-174-XGetPointerControl.patch b/recipes/xorg-driver/xf86-input-tslib/xserver-174-XGetPointerControl.patch
new file mode 100644
index 0000000..a1f6ba8
--- /dev/null
+++ b/recipes/xorg-driver/xf86-input-tslib/xserver-174-XGetPointerControl.patch
@@ -0,0 +1,34 @@
+From Grazvydas Ignotas
+
+At least xserver 1.7.4 crashes on XGetPointerControl request because of xf86-input-tslib:
+
+Program received signal SIGSEGV, Segmentation fault.
+#0  0x000355e0 in ProcGetPointerControl (client=0x4a2e58) at devices.c:2122
+#1  0x00062fa8 in Dispatch () at dispatch.c:439
+#2  0x00022444 in main (argc=4, argv=0xbeebedc4, envp=0xbeebedd8) at main.c:285
+
+This happens because ptrfeed field is not set in device structure from tslib.
+To fix this, call InitPtrFeedbackClassDeviceStruct() during DEVICE_INIT to get necessary setup done (as done in other input drivers).
+
+---
+diff -ur xf86-input-tslib-0.0.6/src/tslib.c xf86-input-tslib-0.0.6_/src/tslib.c
+--- xf86-input-tslib-0.0.6/src/tslib.c	2010-02-09 12:23:22.000000000 +0200
++++ xf86-input-tslib-0.0.6_/src/tslib.c	2010-02-09 12:37:33.000000000 +0200
+@@ -103,8 +103,6 @@
+ static void
+ PointerControlProc(DeviceIntPtr dev, PtrCtrl * ctrl)
+ {
+-	ErrorF("%s\n", __FUNCTION__);
+-	return;
+ }
+ 
+ static Bool
+@@ -406,6 +404,8 @@
+ 		xf86MotionHistoryAllocate(pInfo);
+ #endif
+ 
++		if (!InitPtrFeedbackClassDeviceStruct(device, PointerControlProc))
++			return !Success;
+ 		break;
+ 
+ 	case DEVICE_ON:
diff --git a/recipes/xorg-driver/xf86-input-tslib_0.0.6.bb b/recipes/xorg-driver/xf86-input-tslib_0.0.6.bb
index 6918ff4..6252459 100644
--- a/recipes/xorg-driver/xf86-input-tslib_0.0.6.bb
+++ b/recipes/xorg-driver/xf86-input-tslib_0.0.6.bb
@@ -4,11 +4,13 @@ DESCRIPTION = "X.Org X server -- tslib input driver"
 RRECOMMENDS += "hal tslib-calibrate"
 DEPENDS += "tslib"
 
-PR = "r10"
+PR = "r11"
 
 SRC_URI = "http://www.pengutronix.de/software/xf86-input-tslib/download/xf86-input-tslib-${PV}.tar.bz2 \
-	   file://double-free-crash.patch;patch=1 \
-           file://10-x11-input-tslib.fdi"
+           file://double-free-crash.patch;patch=1 \
+           file://10-x11-input-tslib.fdi \
+           file://xserver-174-XGetPointerControl.patch;patch=1 \
+"
 
 do_configure_prepend() {
 	rm -rf ${S}/m4/ || true





More information about the Openembedded-commits mailing list