From ba801fdb42e1f8dde485cd3f8df7431aa02fa1f2 Mon Sep 17 00:00:00 2001 From: Ben Hutchings Date: Sun, 24 Jun 2012 21:13:18 +0000 Subject: [PATCH] wacom: Try to fix regressions in 3.2.18-1 svn path=/dists/sid/linux/; revision=19197 --- debian/changelog | 3 ++ ...rn-proper-error-if-usb_get_extra_des.patch | 7 ++-- .../wacom/0027-wacom-patch-for-testing.patch | 37 +++++++++++++++++++ debian/patches/series | 5 ++- 4 files changed, 47 insertions(+), 5 deletions(-) create mode 100644 debian/patches/features/all/wacom/0027-wacom-patch-for-testing.patch diff --git a/debian/changelog b/debian/changelog index 0e4811c2d..fd83b0873 100644 --- a/debian/changelog +++ b/debian/changelog @@ -16,6 +16,9 @@ linux (3.2.21-2) UNRELEASED; urgency=low nic-shared-modules, pcmcia-modules - [powerpc,ppc64,x86] scsi-modules depends on ata-modules - [x86] nic-extra-modules depends on i2c-modules + * wacom: Fix crash when probing some MT devices (Closes: #678798) + * wacom: Revert addition of 0xE5 (MT device) support, which causes + regressions for other devices (Closes: #677164) -- Ben Hutchings Sat, 23 Jun 2012 20:19:15 +0100 diff --git a/debian/patches/features/all/wacom/0026-Input-wacom-return-proper-error-if-usb_get_extra_des.patch b/debian/patches/features/all/wacom/0026-Input-wacom-return-proper-error-if-usb_get_extra_des.patch index 8b714a64f..db83db2dc 100644 --- a/debian/patches/features/all/wacom/0026-Input-wacom-return-proper-error-if-usb_get_extra_des.patch +++ b/debian/patches/features/all/wacom/0026-Input-wacom-return-proper-error-if-usb_get_extra_des.patch @@ -10,6 +10,8 @@ error codde returned by usb_get_extra_descriptor(). Reviewed-by: Chris Bagwell Signed-off-by: Dmitry Torokhov +[bwh: Adjust context to apply without preceding + commit 1963518b9b1b8019d33b4b08deee6f873ffa2730] --- drivers/input/tablet/wacom_sys.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) @@ -19,8 +21,8 @@ index 364f2c343..8f3b30b 100644 --- a/drivers/input/tablet/wacom_sys.c +++ b/drivers/input/tablet/wacom_sys.c @@ -517,11 +517,12 @@ static int wacom_retrieve_hid_descriptor(struct usb_interface *intf, + (features->type != BAMBOO_PT)) goto out; - } - if (usb_get_extra_descriptor(interface, HID_DEVICET_HID, &hid_desc)) { - if (usb_get_extra_descriptor(&interface->endpoint[0], @@ -36,6 +38,3 @@ index 364f2c343..8f3b30b 100644 goto out; } } --- -1.7.10 - diff --git a/debian/patches/features/all/wacom/0027-wacom-patch-for-testing.patch b/debian/patches/features/all/wacom/0027-wacom-patch-for-testing.patch new file mode 100644 index 000000000..f1aef2588 --- /dev/null +++ b/debian/patches/features/all/wacom/0027-wacom-patch-for-testing.patch @@ -0,0 +1,37 @@ +From: Ping Cheng +Date: Sun, 24 Jun 2012 09:48:03 -0500 +Subject: wacom: patch for testing +Bug-Debian: http://bugs.debian.org/678798 + +When rep_data was an array + + unsigned char rep_data[2]; + +spelling its address as &rep_data was perfectly valid, but now that +it is dynamically allocated + + unsigned char *rep_data = kmalloc(2, GFP_KERNEL); + +that expression returns a pointer to the pointer rather than to the +array itself. Regression introduced by commit f393ee2b814e (Input: +wacom - retrieve maximum number of touch points, 2012-04-29). +--- + drivers/input/tablet/wacom_sys.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/drivers/input/tablet/wacom_sys.c b/drivers/input/tablet/wacom_sys.c +index cad5602d3ce4..6b1cd71ba320 100644 +--- a/drivers/input/tablet/wacom_sys.c ++++ b/drivers/input/tablet/wacom_sys.c +@@ -216,7 +216,7 @@ static void wacom_retrieve_report_data(struct usb_interface *intf, + + rep_data[0] = 12; + result = wacom_get_report(intf, WAC_HID_FEATURE_REPORT, +- rep_data[0], &rep_data, 2, ++ rep_data[0], rep_data, 2, + WAC_MSG_RETRIES); + + if (result >= 0 && rep_data[1] > 2) +-- +1.7.11.rc3 + diff --git a/debian/patches/series b/debian/patches/series index ecd31ac8e..ba4ccc873 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -204,8 +204,11 @@ features/all/wacom/0021-Input-wacom-add-Intuos5-Touch-Ring-ExpressKey-suppor.pat features/all/wacom/0022-Input-wacom-add-Intuos5-Touch-Ring-LED-support.patch features/all/wacom/0023-Input-wacom-add-Intuos5-multitouch-sensor-support.patch features/all/wacom/0024-Input-wacom-retrieve-maximum-number-of-touch-points.patch -features/all/wacom/0025-Input-wacom-add-0xE5-MT-device-support.patch +# This caused a regression (#677164) and will need a further fix on top +#features/all/wacom/0025-Input-wacom-add-0xE5-MT-device-support.patch features/all/wacom/0026-Input-wacom-return-proper-error-if-usb_get_extra_des.patch +# Preliminary fix for another regression (#678798) +features/all/wacom/0027-wacom-patch-for-testing.patch # Add support for Ralink RT5392/RF5372 chipset features/all/rt2x00-add-debug-message-for-new-chipset.patch