aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/hid/hid-magicmouse.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/hid/hid-magicmouse.c')
-rw-r--r--drivers/hid/hid-magicmouse.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/drivers/hid/hid-magicmouse.c b/drivers/hid/hid-magicmouse.c
index 0ec91c18a421..a5eda4c8127a 100644
--- a/drivers/hid/hid-magicmouse.c
+++ b/drivers/hid/hid-magicmouse.c
@@ -501,9 +501,17 @@ static int magicmouse_probe(struct hid_device *hdev,
501 } 501 }
502 report->size = 6; 502 report->size = 6;
503 503
504 /*
505 * The device reponds with 'invalid report id' when feature
506 * report switching it into multitouch mode is sent to it.
507 *
508 * This results in -EIO from the _raw low-level transport callback,
509 * but there seems to be no other way of switching the mode.
510 * Thus the super-ugly hacky success check below.
511 */
504 ret = hdev->hid_output_raw_report(hdev, feature, sizeof(feature), 512 ret = hdev->hid_output_raw_report(hdev, feature, sizeof(feature),
505 HID_FEATURE_REPORT); 513 HID_FEATURE_REPORT);
506 if (ret != sizeof(feature)) { 514 if (ret != -EIO) {
507 hid_err(hdev, "unable to request touch data (%d)\n", ret); 515 hid_err(hdev, "unable to request touch data (%d)\n", ret);
508 goto err_stop_hw; 516 goto err_stop_hw;
509 } 517 }