summaryrefslogtreecommitdiff
path: root/drivers/hid/hid-ezkey.c
diff options
context:
space:
mode:
authorDavid Herrmann <dh.herrmann@googlemail.com>2011-07-05 11:45:14 (GMT)
committerJiri Kosina <jkosina@suse.cz>2011-07-11 12:30:23 (GMT)
commit23c063cb02b69244bbc215cb81c2cad0208fbecf (patch)
tree0fdf0243e91640dc3e072790a16f61f351d7e3ad /drivers/hid/hid-ezkey.c
parent0c218f14487fd67e60059458c48b43cc3d36b96e (diff)
downloadlinux-fsl-qoriq-23c063cb02b69244bbc215cb81c2cad0208fbecf.tar.xz
HID: wiimote: Add output queue for wiimote driver
The raw hid output function that is supported by bluetooth low-level hid driver does not provide an output queue and also may sleep. The wiimote driver, though, may need to send data in atomic context so this patch adds a buffered output queue for the wiimote driver. We use the shared workqueue to send our buffer to the hid device. There is always only one active worker which flushes the whole output queue to the device. If our queue is full, every further output is discarded. Special care is needed in the deinitialization routine. When wiimote_hid_remove is called, HID input is already disabled, but HID output may still be used from our worker and is then discarded by the lower HID layers. Therefore, we can safely disable the input layer since it is the only layer that still sends input events. Future sysfs attributes must be freed before unregistering input to avoid the sysfs handlers to send input events to a non-existing input layer. Signed-off-by: David Herrmann <dh.herrmann@googlemail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/hid/hid-ezkey.c')
0 files changed, 0 insertions, 0 deletions