]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
[PATCH] Input: fix an OOPS in HID driver
authorDmitry Torokhov <dtor_core@ameritech.net>
Thu, 22 Dec 2005 04:13:17 +0000 (23:13 -0500)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 27 Dec 2005 00:08:58 +0000 (16:08 -0800)
This patch fixes an OOPS in HID driver when connecting simulation
devices generating unknown simulation events.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Acked-by: Vojtech Pavlik <vojtech@suse.cz>
Signed-off-by: Chris Wright <chrisw@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/input/hid-input.c

index 0b6452248a398ae38c47848d66416ea6dd07fcfc..f72d705f0be78a9068c5b10ca878e0bfe9d902ff 100644 (file)
@@ -137,6 +137,7 @@ static void hidinput_configure_usage(struct hid_input *hidinput, struct hid_fiel
                        switch (usage->hid & 0xffff) {
                                case 0xba: map_abs(ABS_RUDDER); break;
                                case 0xbb: map_abs(ABS_THROTTLE); break;
+                               default:   goto ignore;
                        }
                        break;