Use upstream Magicmouse patch
This commit is contained in:
parent
0dd8943dd9
commit
be7c8ca14b
@ -1,53 +0,0 @@
|
||||
From 23746a66d7d9e73402c68ef00d708796b97ebd72 Mon Sep 17 00:00:00 2001
|
||||
From: Jiri Kosina <jkosina@suse.cz>
|
||||
Date: Thu, 19 May 2011 17:58:07 +0200
|
||||
Subject: HID: magicmouse: ignore 'ivalid report id' while switching
|
||||
modes
|
||||
|
||||
From: Jiri Kosina <jkosina@suse.cz>
|
||||
|
||||
commit 23746a66d7d9e73402c68ef00d708796b97ebd72 upstream.
|
||||
|
||||
The device reponds with 'invalid report id' when feature report switching it
|
||||
into multitouch mode is sent to it.
|
||||
|
||||
This has been silently ignored before 0825411ade ("HID: bt: Wait for ACK
|
||||
on Sent Reports"), but since this commit, it propagates -EIO from the _raw
|
||||
callback .
|
||||
|
||||
So let the driver ignore -EIO as response to 0xd7,0x01 report, as that's
|
||||
how the device reacts in normal mode.
|
||||
|
||||
Sad, but following reality.
|
||||
|
||||
This fixes https://bugzilla.kernel.org/show_bug.cgi?id=35022
|
||||
|
||||
Tested-by: Chase Douglas <chase.douglas@canonical.com>
|
||||
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
|
||||
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
||||
|
||||
---
|
||||
drivers/hid/hid-magicmouse.c | 10 +++++++++-
|
||||
1 file changed, 9 insertions(+), 1 deletion(-)
|
||||
|
||||
--- a/drivers/hid/hid-magicmouse.c
|
||||
+++ b/drivers/hid/hid-magicmouse.c
|
||||
@@ -501,9 +501,17 @@ static int magicmouse_probe(struct hid_d
|
||||
}
|
||||
report->size = 6;
|
||||
|
||||
+ /*
|
||||
+ * The device reponds with 'invalid report id' when feature
|
||||
+ * report switching it into multitouch mode is sent to it.
|
||||
+ *
|
||||
+ * This results in -EIO from the _raw low-level transport callback,
|
||||
+ * but there seems to be no other way of switching the mode.
|
||||
+ * Thus the super-ugly hacky success check below.
|
||||
+ */
|
||||
ret = hdev->hid_output_raw_report(hdev, feature, sizeof(feature),
|
||||
HID_FEATURE_REPORT);
|
||||
- if (ret != sizeof(feature)) {
|
||||
+ if (ret != -EIO) {
|
||||
hid_err(hdev, "unable to request touch data (%d)\n", ret);
|
||||
goto err_stop_hw;
|
||||
}
|
11
kernel.spec
11
kernel.spec
@ -649,9 +649,10 @@ Patch394: linux-2.6-acpi-debug-infinite-loop.patch
|
||||
|
||||
Patch450: linux-2.6-input-kill-stupid-messages.patch
|
||||
Patch452: linux-2.6.30-no-pcspkr-modalias.patch
|
||||
# revert 2.6.38.8 patch that broke magicmouse
|
||||
Patch453: hid-magicmouse-ignore-ivalid-report-id-while-switching.patch
|
||||
Patch453: revert-hid-magicmouse-ignore-ivalid-report-id-while-switching.patch
|
||||
Patch454: input-wacom-add-support-for-lenovo-tablet-id-0xe6.patch
|
||||
Patch455: hid-ntrig-deref-unclaimed-input.patch
|
||||
Patch456: hid-multitouch-add-support-for-elo-touchsystems.patch
|
||||
|
||||
Patch460: linux-2.6-serial-460800.patch
|
||||
|
||||
@ -771,9 +772,6 @@ Patch12404: x86-pci-preserve-existing-pci-bfsort-whitelist-for-dell-systems.patc
|
||||
|
||||
Patch12407: scsi_dh_hp_sw-fix-deadlock-in-start_stop_endio.patch
|
||||
|
||||
Patch12410: hid-ntrig-deref-unclaimed-input.patch
|
||||
|
||||
Patch12415: hid-multitouch-add-support-for-elo-touchsystems.patch
|
||||
Patch12416: bluetooth-device-ids-for-ath3k-on-pegatron-lucid-tablets.patch
|
||||
|
||||
|
||||
@ -1337,8 +1335,7 @@ ApplyPatch hda_intel-prealloc-4mb-dmabuffer.patch
|
||||
# The input layer spews crap no-one cares about.
|
||||
ApplyPatch linux-2.6-input-kill-stupid-messages.patch
|
||||
ApplyPatch linux-2.6.30-no-pcspkr-modalias.patch
|
||||
# Revert 2.6.38.8 patch that broke magicmouse
|
||||
ApplyPatch hid-magicmouse-ignore-ivalid-report-id-while-switching.patch -R
|
||||
ApplyPatch revert-hid-magicmouse-ignore-ivalid-report-id-while-switching.patch
|
||||
ApplyPatch input-wacom-add-support-for-lenovo-tablet-id-0xe6.patch
|
||||
ApplyPatch hid-ntrig-deref-unclaimed-input.patch
|
||||
ApplyPatch hid-multitouch-add-support-for-elo-touchsystems.patch
|
||||
|
@ -0,0 +1,43 @@
|
||||
From: Jiri Kosina <jkosina@suse.cz>
|
||||
Date: Thu, 16 Jun 2011 10:21:34 +0000 (+0200)
|
||||
Subject: Revert "HID: magicmouse: ignore 'ivalid report id' while switching modes"
|
||||
X-Git-Tag: v3.0-rc4~20^2
|
||||
X-Git-Url: http://git.kernel.org/?p=linux%2Fkernel%2Fgit%2Ftorvalds%2Flinux-2.6.git;a=commitdiff_plain;h=c3a4924565e2eecf2539871abd123d35be6d76d5
|
||||
|
||||
Revert "HID: magicmouse: ignore 'ivalid report id' while switching modes"
|
||||
|
||||
This reverts commit 23746a66d7d9e73402c68ef00d708796b97ebd72.
|
||||
|
||||
It turned out that the actual reason for failure is not the device
|
||||
firmware, but bug in Bluetooth stack, which will be fixed by
|
||||
patch by Ville Tervo which corrects the mask handling for CSR 1.1
|
||||
Dongles.
|
||||
|
||||
Reported-and-tested-by: Ed Tomlinson <edt@aei.ca>
|
||||
Reported-and-tested-by: Chase Douglas <chase.douglas@canonical.com>
|
||||
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
|
||||
---
|
||||
|
||||
diff --git a/drivers/hid/hid-magicmouse.c b/drivers/hid/hid-magicmouse.c
|
||||
index a5eda4c..0ec91c1 100644
|
||||
--- a/drivers/hid/hid-magicmouse.c
|
||||
+++ b/drivers/hid/hid-magicmouse.c
|
||||
@@ -501,17 +501,9 @@ static int magicmouse_probe(struct hid_device *hdev,
|
||||
}
|
||||
report->size = 6;
|
||||
|
||||
- /*
|
||||
- * The device reponds with 'invalid report id' when feature
|
||||
- * report switching it into multitouch mode is sent to it.
|
||||
- *
|
||||
- * This results in -EIO from the _raw low-level transport callback,
|
||||
- * but there seems to be no other way of switching the mode.
|
||||
- * Thus the super-ugly hacky success check below.
|
||||
- */
|
||||
ret = hdev->hid_output_raw_report(hdev, feature, sizeof(feature),
|
||||
HID_FEATURE_REPORT);
|
||||
- if (ret != -EIO) {
|
||||
+ if (ret != sizeof(feature)) {
|
||||
hid_err(hdev, "unable to request touch data (%d)\n", ret);
|
||||
goto err_stop_hw;
|
||||
}
|
Loading…
Reference in New Issue
Block a user