HID: hid-input: fix stylus battery reporting
authorDmitry Torokhov <dmitry.torokhov@gmail.com>
Fri, 25 Sep 2020 23:35:52 +0000 (16:35 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 29 Oct 2020 08:07:06 +0000 (09:07 +0100)
commit9fccdf49813ea8aac9475772264f248f21deb214
tree658f518604e319a49e9cbda6c2e6251f7b5fd4c6
parentd996dee5ff9c0db537fa189f8487544311d85e74
HID: hid-input: fix stylus battery reporting

[ Upstream commit 505f394fa239cecb76d916aa858f87ed7ea7fde4 ]

With commit 4f3882177240 hid-input started clearing of "ignored" usages
to avoid using garbage that might have been left in them. However
"battery strength" usages should not be ignored, as we do want to
use them.

Fixes: 4f3882177240 ("HID: hid-input: clear unmapped usages")
Reported-by: Kenneth Albanowski <kenalba@google.com>
Tested-by: Kenneth Albanowski <kenalba@google.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/hid/hid-input.c