summaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorDean Camera <dean@fourwalledcubicle.com>2020-11-25 23:39:57 +0100
committerJiri Kosina <jkosina@suse.cz>2020-11-27 15:48:31 +0100
commitf43d3870cafa2a0f3854c1819c8385733db8f9ae (patch)
treecf265121361d49572f7941734bffaa3b4611e386 /kernel
parentHID: Increase HID maximum report size to 16KB (diff)
downloadlinux-f43d3870cafa2a0f3854c1819c8385733db8f9ae.tar.xz
linux-f43d3870cafa2a0f3854c1819c8385733db8f9ae.zip
HID: hidraw: Add additional hidraw input/output report ioctls.
Currently the hidraw module can only read and write feature HID reports on demand, via dedicated ioctls. Input reports are read from the device through the read() interface, while output reports are written through the write interface(). This is insufficient; it is desirable in many situations to be able to read and write input and output reports through the control interface to cover additional scenarios: - Reading an input report by its report ID, to get initial state - Writing an input report, to set initial input state in the device - Reading an output report by its report ID, to obtain current state - Writing an output report by its report ID, out of band This patch adds these missing ioctl requests to read and write the remaining HID report types. Note that not all HID backends will neccesarily support this (e.g. while the USB link layer supports setting Input reports, others may not). Also included are documentation and example updates. The current hidraw documentation states that feature reports read from the device does *not* include the report ID, however this is not the case and the returned report will have its report ID prepended by conforming HID devices, as the report data sent from the device over the control endpoint must be indentical in format to those sent over the regular transport. Signed-off-by: Dean Camera <dean@fourwalledcubicle.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'kernel')
0 files changed, 0 insertions, 0 deletions