]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit
HID: wacom: Do not completely map WACOM_HID_WD_TOUCHRINGSTATUS usage
authorJason Gerecke <killertofu@gmail.com>
Fri, 4 Aug 2017 22:35:14 +0000 (15:35 -0700)
committerSeth Forshee <seth.forshee@canonical.com>
Sun, 10 Sep 2017 23:08:46 +0000 (18:08 -0500)
commit20488fa506aeb3939c104b0e140f884116d29513
tree4289cab7158a4ce8aacb2e16739b7265b4a87e03
parentc74cc7adef2dae1131159ddab2cd95137ff0c3bc
HID: wacom: Do not completely map WACOM_HID_WD_TOUCHRINGSTATUS usage

BugLink: http://bugs.launchpad.net/bugs/1716284
commit 8d411cbf46e515ca2b7ceb3d2b3f43e22813edac upstream.

The WACOM_HID_WD_TOUCHRINGSTATUS usage is a single bit which tells us
whether the touchring is currently in use or not. Because we need to
reset the axis value to 0 when the finger is removed, we call
'wacom_map_usage' to ensure that the required type/code values are
associated with the usage. The 'wacom_map_usage' also sets up the axis
range and resolution, however, which is not desired in this particular
case.

Although xf86-input-wacom doesn't do really do anything with the ring's
range or resolution, the libinput driver (for Wayland environments)
uses these values to provide proper angle indications to userspace.

Fixes: 60a2218698 ("HID: wacom: generic: add support for touchring")
Signed-off-by: Jason Gerecke <jason.gerecke@wacom.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
drivers/hid/wacom_wac.c