* [PATCH] HID: Fix dropped device-specific quirks
@ 2009-05-04 16:57 Zoltan Karcagi
2009-05-06 14:35 ` Jiri Kosina
0 siblings, 1 reply; 2+ messages in thread
From: Zoltan Karcagi @ 2009-05-04 16:57 UTC (permalink / raw)
To: linux-input
Hi,
(Originally sent to linux-usb, description slightly rephrased.)
Please consider for merging. Without this patch, the device below does not work at all on kernel 2.6.28
and upwards.
Device-specific quirks are set up correctly in their respective vendor-specific driver, then
get overwritten in usbhid_parse().
Found on a Microsoft Wireless Optical Desktop 3.0 [045e:009d].
Signed-off-by: Zoltan Karcagi <zkr@freemail.hu>
diff -r -U 5 linux-2.6.30-rc4/drivers/hid/usbhid/hid-core.c linux-2.6.30-rc4-fixed/drivers/hid/usbhid/hid-core.c
--- linux-2.6.30-rc4/drivers/hid/usbhid/hid-core.c 2009-05-01 12:06:18.000000000 +0200
+++ linux-2.6.30-rc4-fixed/drivers/hid/usbhid/hid-core.c 2009-05-03 14:43:47.000000000 +0200
@@ -896,11 +896,11 @@
if (ret) {
dbg_hid("parsing report descriptor failed\n");
goto err;
}
- hid->quirks = quirks;
+ hid->quirks |= quirks;
return 0;
err:
return ret;
}
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] HID: Fix dropped device-specific quirks
2009-05-04 16:57 [PATCH] HID: Fix dropped device-specific quirks Zoltan Karcagi
@ 2009-05-06 14:35 ` Jiri Kosina
0 siblings, 0 replies; 2+ messages in thread
From: Jiri Kosina @ 2009-05-06 14:35 UTC (permalink / raw)
To: Zoltan Karcagi; +Cc: linux-input
On Mon, 4 May 2009, Zoltan Karcagi wrote:
> Device-specific quirks are set up correctly in their respective
> vendor-specific driver, then get overwritten in usbhid_parse(). Found on
> a Microsoft Wireless Optical Desktop 3.0 [045e:009d].
Good catch, thanks. Fortunately this affects only a few devices out there,
for which specialized drivers set hdrv->quirks specifically (mostly NOGET
quirk only).
> Signed-off-by: Zoltan Karcagi <zkr@freemail.hu>
>
> diff -r -U 5 linux-2.6.30-rc4/drivers/hid/usbhid/hid-core.c
> linux-2.6.30-rc4-fixed/drivers/hid/usbhid/hid-core.c
> --- linux-2.6.30-rc4/drivers/hid/usbhid/hid-core.c 2009-05-01
> 12:06:18.000000000 +0200
> +++ linux-2.6.30-rc4-fixed/drivers/hid/usbhid/hid-core.c 2009-05-03
> 14:43:47.000000000 +0200
> @@ -896,11 +896,11 @@
> if (ret) {
> dbg_hid("parsing report descriptor failed\n");
> goto err;
> }
>
> - hid->quirks = quirks;
> + hid->quirks |= quirks;
>
> return 0;
> err:
> return ret;
> }
The patch has been whitespace damaged, please fix this for your further
submissions.
I have fixed it manually and applied.
Thanks,
--
Jiri Kosina
SUSE Labs
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-05-06 14:35 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-05-04 16:57 [PATCH] HID: Fix dropped device-specific quirks Zoltan Karcagi
2009-05-06 14:35 ` Jiri Kosina
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).