aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/input/hid-input.c
diff options
context:
space:
mode:
authorVojtech Pavlik <vojtech@suse.cz>2005-09-05 01:07:59 -0400
committerDmitry Torokhov <dtor_core@ameritech.net>2005-09-05 01:07:59 -0400
commit0aebfdac042b63d0f2625414062e138a4333181c (patch)
tree44d08bf2575e2dc16d304891cc90711bfd2fdf94 /drivers/usb/input/hid-input.c
parentb8c9c642db4ab0811cc5bb0d8b90cc7819055c95 (diff)
Input: add HID simulation mappings
Add simulation usage page mappings to hid-input.c to support a new crop of joysticks using them to designate Rudder and Throttle controls. Signed-off-by: Vojtech Pavlik <vojtech@suse.cz> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/usb/input/hid-input.c')
-rw-r--r--drivers/usb/input/hid-input.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/usb/input/hid-input.c b/drivers/usb/input/hid-input.c
index 3b162a19d7b5..fa4f79d88aa7 100644
--- a/drivers/usb/input/hid-input.c
+++ b/drivers/usb/input/hid-input.c
@@ -131,6 +131,15 @@ static void hidinput_configure_usage(struct hid_input *hidinput, struct hid_fiel
131 map_key(code); 131 map_key(code);
132 break; 132 break;
133 133
134
135 case HID_UP_SIMULATION:
136
137 switch (usage->hid & 0xffff) {
138 case 0xba: map_abs(ABS_RUDDER); break;
139 case 0xbb: map_abs(ABS_THROTTLE); break;
140 }
141 break;
142
134 case HID_UP_GENDESK: 143 case HID_UP_GENDESK:
135 144
136 if ((usage->hid & 0xf0) == 0x80) { /* SystemControl */ 145 if ((usage->hid & 0xf0) == 0x80) { /* SystemControl */