[patch 09/13] joydev: fix button mapping

From: Dmitry Torokhov
Date: Sun May 29 2005 - 00:35:55 EST


From: Vojtech Pavlik <vojtech@xxxxxxx>

Input: Fix button mapping in joydev - BTN_TRIGGER was being
mapped twice, resulting in it being the last (instead
of first) button on a joystick.

Signed-off-by: Vojtech Pavlik <vojtech@xxxxxxx>
Signed-off-by: Dmitry Torokhov <dtor@xxxxxxx>
---

drivers/input/joydev.c | 2 +-
1 files changed, 1 insertion(+), 1 deletion(-)

Index: work/drivers/input/joydev.c
===================================================================
--- work.orig/drivers/input/joydev.c
+++ work/drivers/input/joydev.c
@@ -422,7 +422,7 @@ static struct input_handle *joydev_conne
joydev->nkey++;
}

- for (i = 0; i < BTN_JOYSTICK - BTN_MISC + 1; i++)
+ for (i = 0; i < BTN_JOYSTICK - BTN_MISC; i++)
if (test_bit(i + BTN_MISC, dev->keybit)) {
joydev->keymap[i] = joydev->nkey;
joydev->keypam[joydev->nkey] = i + BTN_MISC;

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/