summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2021-10-28 18:33:30 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-12-01 09:04:48 +0100
commit740dd84229a5c2430720f57348594bfef91eb606 (patch)
tree4de28d8b5c7cb20e86a15099f1655ec8ec9a2a12 /drivers
parent03e5203d2161a00afe4d97d206d2293e40b2f253 (diff)
downloadlinux-stable-740dd84229a5c2430720f57348594bfef91eb606.tar.gz
linux-stable-740dd84229a5c2430720f57348594bfef91eb606.tar.bz2
linux-stable-740dd84229a5c2430720f57348594bfef91eb606.zip
HID: input: Fix parsing of HID_CP_CONSUMER_CONTROL fields
[ Upstream commit 7fc48fd6b2c0acacd8130d83d2a037670d6192d2 ] Fix parsing of HID_CP_CONSUMER_CONTROL fields which are not in the HID_CP_PROGRAMMABLEBUTTONS collection. Fixes: bcfa8d14570d ("HID: input: Add support for Programmable Buttons") BugLink: https://bugzilla.redhat.com/show_bug.cgi?id=2018096 Cc: Thomas Weißschuh <linux@weissschuh.net> Suggested-by: Benjamin Tissoires <btissoir@redhat.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-By: Thomas Weißschuh <linux@weissschuh.net> Signed-off-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/hid/hid-input.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/hid/hid-input.c b/drivers/hid/hid-input.c
index 4b5ebeacd283..4b3f4a5e2305 100644
--- a/drivers/hid/hid-input.c
+++ b/drivers/hid/hid-input.c
@@ -650,10 +650,9 @@ static void hidinput_configure_usage(struct hid_input *hidinput, struct hid_fiel
code += KEY_MACRO1;
else
code += BTN_TRIGGER_HAPPY - 0x1e;
- } else {
- goto ignore;
+ break;
}
- break;
+ fallthrough;
default:
switch (field->physical) {
case HID_GD_MOUSE: