[patch 15/19] [PATCH] Input: fix an OOPS in HID driver

Greg Kroah-Hartman
2005-12-23T22:54:20Z

[-- Attachment #1: input-fix-an-OOPS-in-HID-driver.patch --]
[-- Type: text/plain, Size: 861 bytes --]

-stable review patch. If anyone has any objections, please let us know.

------------------
From: Dmitry Torokhov <dtor_core@ameritech.net>

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 | 1 +
1 file changed, 1 insertion(+)

--- linux-2.6.14.4.orig/drivers/usb/input/hid-input.c
+++ linux-2.6.14.4/drivers/usb/input/hid-input.c
@@ -137,6 +137,7 @@ static void hidinput_configure_usage(str
switch (usage->hid & 0xffff) {
case 0xba: map_abs(ABS_RUDDER); break;
case 0xbb: map_abs(ABS_THROTTLE); break;
+ default: goto ignore;
}
break;

--