summaryrefslogtreecommitdiff
path: root/include/linux/hid.h
diff options
context:
space:
mode:
authorArchana Patni <archana.patni@linux.intel.com>2014-05-08 09:26:19 -0400
committerJiri Kosina <jkosina@suse.cz>2014-05-13 11:19:22 +0200
commitf58b8487bcc898acad3eeea6f950e673d9b79dea (patch)
treedcb378c1bebd0d6abe7d754bb784262deb0a72c7 /include/linux/hid.h
parent7ceeff443be92913f7edd1134d677fa2a1824cd0 (diff)
HID: i2c-hid: hid report descriptor retrieval changes
Reading the partial HID Descriptor is causing a firmware lockup in some sensor hubs. Instead of a partial read, this patch implements the i2c hid fetch using a fixed descriptor size (30 bytes) followed by a verification of the BCDVersion (V01.00), and value stored in wHIDDescLength (30 Bytes) for V1.00 descriptors. As per i2c hid spec, this is the preferred model. From hid-over-i2c-protocol-spec-v1-0: There are a variety of ways a HOST may choose to retrieve the HID Descriptor from the DEVICE. The following is a preferred implementation but should not be considered the only implementation. A HOST may read the entire HID Descriptor in a single read by issuing a read for 30 Bytes to get the entire HID Descriptor from the DEVICE.However, the HOST is responsible for validating that 1. The BCDVersion is V01.00 (later revisions may have different descriptor lengths), and 2. The value stored in wHIDDescLength is 30 (Bytes) for V1.00 descriptors. Reported-by: Joe Tijerina <joe.tijerina@st.com> Signed-off-by: Archana Patni <archana.patni@intel.com> Signed-off-by: Subramony Sesha <subramony.sesha@intel.com> Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com> Reviewed-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'include/linux/hid.h')
0 files changed, 0 insertions, 0 deletions