diff options
| -rw-r--r-- | drivers/input/touchscreen/usbtouchscreen.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/input/touchscreen/usbtouchscreen.c b/drivers/input/touchscreen/usbtouchscreen.c index 09a5e7341bd5..5256123a5228 100644 --- a/drivers/input/touchscreen/usbtouchscreen.c +++ b/drivers/input/touchscreen/usbtouchscreen.c | |||
| @@ -618,8 +618,8 @@ static int idealtek_read_data(struct usbtouch_usb *dev, unsigned char *pkt) | |||
| 618 | #ifdef CONFIG_TOUCHSCREEN_USB_GENERAL_TOUCH | 618 | #ifdef CONFIG_TOUCHSCREEN_USB_GENERAL_TOUCH |
| 619 | static int general_touch_read_data(struct usbtouch_usb *dev, unsigned char *pkt) | 619 | static int general_touch_read_data(struct usbtouch_usb *dev, unsigned char *pkt) |
| 620 | { | 620 | { |
| 621 | dev->x = ((pkt[2] & 0x0F) << 8) | pkt[1] ; | 621 | dev->x = (pkt[2] << 8) | pkt[1]; |
| 622 | dev->y = ((pkt[4] & 0x0F) << 8) | pkt[3] ; | 622 | dev->y = (pkt[4] << 8) | pkt[3]; |
| 623 | dev->press = pkt[5] & 0xff; | 623 | dev->press = pkt[5] & 0xff; |
| 624 | dev->touch = pkt[0] & 0x01; | 624 | dev->touch = pkt[0] & 0x01; |
| 625 | 625 | ||
| @@ -809,9 +809,9 @@ static struct usbtouch_device_info usbtouch_dev_info[] = { | |||
| 809 | #ifdef CONFIG_TOUCHSCREEN_USB_GENERAL_TOUCH | 809 | #ifdef CONFIG_TOUCHSCREEN_USB_GENERAL_TOUCH |
| 810 | [DEVTYPE_GENERAL_TOUCH] = { | 810 | [DEVTYPE_GENERAL_TOUCH] = { |
| 811 | .min_xc = 0x0, | 811 | .min_xc = 0x0, |
| 812 | .max_xc = 0x0500, | 812 | .max_xc = 0x7fff, |
| 813 | .min_yc = 0x0, | 813 | .min_yc = 0x0, |
| 814 | .max_yc = 0x0500, | 814 | .max_yc = 0x7fff, |
| 815 | .rept_size = 7, | 815 | .rept_size = 7, |
| 816 | .read_data = general_touch_read_data, | 816 | .read_data = general_touch_read_data, |
| 817 | }, | 817 | }, |
