hiddev is mistakenly returning empty hiddev_event structures for report
events. According to Documentation/usb/hiddev.txt, report events are
only sent when HIDDEV_FLAG_REPORT and HIDDEV_FLAG_UREF are both set.
Currently, report events from hid cause hiddev to generate empty
hiddev_event events when HIDDEV_FLAG_UREF is not set.

Patch below, against 2.6.0-test11, fixes the problem.

--Adam


--- linux-2.6.0-test11/drivers/usb/input/hiddev.c       Fri Oct 17 23:23:08 2003
+++ linux-2.6.0-test11-adk/drivers/usb/input/hiddev.c   Wed Dec 17 23:38:24 2003
@@ -213,6 +213,7 @@
          ((type == HID_OUTPUT_REPORT) ? HID_REPORT_TYPE_OUTPUT : 
           ((type == HID_FEATURE_REPORT) ? HID_REPORT_TYPE_FEATURE:0));
        uref.report_id = report->id;
+       uref.field_index = HID_FIELD_INDEX_NONE;
 
        hiddev_send_event(hid, &uref);
 }



-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to