usbtouchscreen: fix ITM data reading
authorKai Lindhom <megantti@gmail.com>
Thu, 7 Sep 2006 19:25:51 +0000 (21:25 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 7 Sep 2006 22:23:04 +0000 (15:23 -0700)
From: Kai Lindhom <megantti@gmail.com>
Signed-off-by: Daniel Ritz <daniel.ritz@gmx.ch>
Acked-by: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/input/usbtouchscreen.c

index 3b175aa482cdd276c362e1ef1dec01512adbfc49..a338bf4c2d78eda0cf50ed02b55f240f5e3932b6 100644 (file)
@@ -286,7 +286,7 @@ static int mtouch_init(struct usbtouch_usb *usbtouch)
 static int itm_read_data(unsigned char *pkt, int *x, int *y, int *touch, int *press)
 {
        *x = ((pkt[0] & 0x1F) << 7) | (pkt[3] & 0x7F);
-       *x = ((pkt[1] & 0x1F) << 7) | (pkt[4] & 0x7F);
+       *y = ((pkt[1] & 0x1F) << 7) | (pkt[4] & 0x7F);
        *press = ((pkt[2] & 0x1F) << 7) | (pkt[5] & 0x7F);
        *touch = ~pkt[7] & 0x20;