X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=drivers%2Fusb%2Finput%2Fwacom.c;h=492a5cb12af47f98be9cdae5d85e0b93e3dbfb91;hb=c7b5ebbddf7bcd3651947760f423e3783bbe6573;hp=62298cf759b4e1b8ef18c081f5f829f6a1aa5246;hpb=5273a3df6485dc2ad6aa7ddd441b9a21970f003b;p=linux-2.6.git diff --git a/drivers/usb/input/wacom.c b/drivers/usb/input/wacom.c index 62298cf75..492a5cb12 100644 --- a/drivers/usb/input/wacom.c +++ b/drivers/usb/input/wacom.c @@ -285,8 +285,8 @@ static void wacom_penpartner_irq(struct urb *urb, struct pt_regs *regs) input_regs(dev, regs); input_report_key(dev, BTN_TOOL_PEN, 1); - input_report_abs(dev, ABS_X, le16_to_cpu(get_unaligned((u16 *) &data[1]))); - input_report_abs(dev, ABS_Y, le16_to_cpu(get_unaligned((u16 *) &data[3]))); + input_report_abs(dev, ABS_X, le16_to_cpu(get_unaligned((__le16 *) &data[1]))); + input_report_abs(dev, ABS_Y, le16_to_cpu(get_unaligned((__le16 *) &data[3]))); input_report_abs(dev, ABS_PRESSURE, (signed char)data[6] + 127); input_report_key(dev, BTN_TOUCH, ((signed char)data[6] > -80) && !(data[5] & 0x20)); input_report_key(dev, BTN_STYLUS, (data[5] & 0x40)); @@ -329,8 +329,8 @@ static void wacom_graphire_irq(struct urb *urb, struct pt_regs *regs) if (data[0] != 2) dbg("wacom_graphire_irq: received unknown report #%d", data[0]); - x = le16_to_cpu(*(u16 *) &data[2]); - y = le16_to_cpu(*(u16 *) &data[4]); + x = le16_to_cpu(*(__le16 *) &data[2]); + y = le16_to_cpu(*(__le16 *) &data[4]); input_regs(dev, regs); @@ -367,7 +367,7 @@ static void wacom_graphire_irq(struct urb *urb, struct pt_regs *regs) input_report_abs(dev, ABS_Y, y); } - input_report_abs(dev, ABS_PRESSURE, le16_to_cpu(*(u16 *) &data[6])); + input_report_abs(dev, ABS_PRESSURE, le16_to_cpu(*(__le16 *) &data[6])); input_report_key(dev, BTN_TOUCH, data[1] & 0x01); input_report_key(dev, BTN_STYLUS, data[1] & 0x02); input_report_key(dev, BTN_STYLUS2, data[1] & 0x04); @@ -456,8 +456,8 @@ static void wacom_intuos_irq(struct urb *urb, struct pt_regs *regs) goto exit; } - input_report_abs(dev, ABS_X, be16_to_cpu(*(u16 *) &data[2])); - input_report_abs(dev, ABS_Y, be16_to_cpu(*(u16 *) &data[4])); + input_report_abs(dev, ABS_X, be16_to_cpu(*(__be16 *) &data[2])); + input_report_abs(dev, ABS_Y, be16_to_cpu(*(__be16 *) &data[4])); input_report_abs(dev, ABS_DISTANCE, data[9]); if ((data[1] & 0xb8) == 0xa0) { /* general pen packet */ @@ -527,7 +527,7 @@ exit: __FUNCTION__, retval); } -struct wacom_features wacom_features[] = { +static struct wacom_features wacom_features[] = { { "Wacom Penpartner", 7, 5040, 3780, 255, 32, 0, wacom_penpartner_irq }, { "Wacom Graphire", 8, 10206, 7422, 511, 32, 1, wacom_graphire_irq }, { "Wacom Graphire2 4x5", 8, 10206, 7422, 511, 32, 1, wacom_graphire_irq }, @@ -556,7 +556,7 @@ struct wacom_features wacom_features[] = { { } }; -struct usb_device_id wacom_ids[] = { +static struct usb_device_id wacom_ids[] = { { USB_DEVICE(USB_VENDOR_ID_WACOM, 0x00) }, { USB_DEVICE(USB_VENDOR_ID_WACOM, 0x10) }, { USB_DEVICE(USB_VENDOR_ID_WACOM, 0x11) },