aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/hid/hid-apple.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/hid/hid-apple.c')
-rw-r--r--drivers/hid/hid-apple.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/drivers/hid/hid-apple.c b/drivers/hid/hid-apple.c
index 2a68661fcea..f0b177844cf 100644
--- a/drivers/hid/hid-apple.c
+++ b/drivers/hid/hid-apple.c
@@ -309,6 +309,7 @@ static int apple_probe(struct hid_device *hdev,
309{ 309{
310 unsigned long quirks = id->driver_data; 310 unsigned long quirks = id->driver_data;
311 struct apple_sc *asc; 311 struct apple_sc *asc;
312 unsigned int connect_mask = HID_CONNECT_DEFAULT;
312 int ret; 313 int ret;
313 314
314 /* return something else or move to hid layer? device will reside 315 /* return something else or move to hid layer? device will reside
@@ -328,18 +329,18 @@ static int apple_probe(struct hid_device *hdev,
328 329
329 hid_set_drvdata(hdev, asc); 330 hid_set_drvdata(hdev, asc);
330 331
331 if (quirks & APPLE_HIDDEV)
332 hdev->quirks |= HID_QUIRK_HIDDEV;
333 if (quirks & APPLE_IGNORE_HIDINPUT)
334 hdev->quirks |= HID_QUIRK_IGNORE_HIDINPUT;
335
336 ret = hid_parse(hdev); 332 ret = hid_parse(hdev);
337 if (ret) { 333 if (ret) {
338 dev_err(&hdev->dev, "parse failed\n"); 334 dev_err(&hdev->dev, "parse failed\n");
339 goto err_free; 335 goto err_free;
340 } 336 }
341 337
342 ret = hid_hw_start(hdev); 338 if (quirks & APPLE_HIDDEV)
339 connect_mask |= HID_CONNECT_HIDDEV_FORCE;
340 if (quirks & APPLE_IGNORE_HIDINPUT)
341 connect_mask &= ~HID_CONNECT_HIDINPUT;
342
343 ret = hid_hw_start(hdev, connect_mask);
343 if (ret) { 344 if (ret) {
344 dev_err(&hdev->dev, "hw start failed\n"); 345 dev_err(&hdev->dev, "hw start failed\n");
345 goto err_free; 346 goto err_free;