* [PATCH 1/3] bluetooth: hidp+hidraw disconnect
@ 2009-09-10 17:40 SephirXV
2009-09-10 17:44 ` Marcel Holtmann
0 siblings, 1 reply; 2+ messages in thread
From: SephirXV @ 2009-09-10 17:40 UTC (permalink / raw)
To: linux-bluetooth
From: Christopher Olson <sephirxv@gmail.com>
Somewhere between 2.6.26 and 2.6.28, hidraw began connecting to HIDP
devices which don't strictly define their behavior in the HID usage
table, and without any patching on my part. These non-compliant
devices wouldn't automatically disconnect, leaving hidraw files which
did nothing.
Signed-off-by: Christopher Olson <sephirxv@gmail.com>
---
--- net/bluetooth/hidp/core.c 2009-09-10 09:32:20.000000000 -0500
+++ net/bluetooth/hidp/core.c.1 2009-09-10 09:31:37.000000000 -0500
@@ -40,6 +40,7 @@
#include <linux/input.h>
#include <linux/hid.h>
+#include <linux/hidraw.h>
#include <net/bluetooth/bluetooth.h>
#include <net/bluetooth/hci_core.h>
@@ -736,6 +737,8 @@ static void hidp_stop(struct hid_device
if (hid->claimed & HID_CLAIMED_INPUT)
hidinput_disconnect(hid);
+ if (hid->claimed & HID_CLAIMED_HIDRAW)
+ hidraw_disconnect(hid);
hid->claimed = 0;
}
^ permalink raw reply [flat|nested] 2+ messages in thread* Re: [PATCH 1/3] bluetooth: hidp+hidraw disconnect
2009-09-10 17:40 [PATCH 1/3] bluetooth: hidp+hidraw disconnect SephirXV
@ 2009-09-10 17:44 ` Marcel Holtmann
0 siblings, 0 replies; 2+ messages in thread
From: Marcel Holtmann @ 2009-09-10 17:44 UTC (permalink / raw)
To: SephirXV; +Cc: linux-bluetooth
Hi Christopher,
> Somewhere between 2.6.26 and 2.6.28, hidraw began connecting to HIDP
> devices which don't strictly define their behavior in the HID usage
> table, and without any patching on my part. These non-compliant
> devices wouldn't automatically disconnect, leaving hidraw files which
> did nothing.
>
> Signed-off-by: Christopher Olson <sephirxv@gmail.com>
>
> ---
>
> --- net/bluetooth/hidp/core.c 2009-09-10 09:32:20.000000000 -0500
> +++ net/bluetooth/hidp/core.c.1 2009-09-10 09:31:37.000000000 -0500
> @@ -40,6 +40,7 @@
>
> #include <linux/input.h>
> #include <linux/hid.h>
> +#include <linux/hidraw.h>
>
> #include <net/bluetooth/bluetooth.h>
> #include <net/bluetooth/hci_core.h>
> @@ -736,6 +737,8 @@ static void hidp_stop(struct hid_device
>
> if (hid->claimed & HID_CLAIMED_INPUT)
> hidinput_disconnect(hid);
> + if (hid->claimed & HID_CLAIMED_HIDRAW)
> + hidraw_disconnect(hid);
> hid->claimed = 0;
> }
I am pretty sure such a patch or similar is in net-next-2.6 already.
Regards
Marcel
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-09-10 17:44 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-09-10 17:40 [PATCH 1/3] bluetooth: hidp+hidraw disconnect SephirXV
2009-09-10 17:44 ` Marcel Holtmann
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox