Commit 952f4a0a authored by Linus Torvalds's avatar Linus Torvalds

Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
  Input: appletouch - implement reset-resume logic
  Input: i8042 - retry failed CTR writes when resuming
  Input: i8042 - add Fujitsu-Siemens Amilo Pro V2030 to nomux table
  Input: pcspkr - remove negative dependency on snd-pcsp

Manually fixed up trivial conflict in drivers/usb/core/quirks.c
parents f948d564 90d95ef6
...@@ -15,7 +15,6 @@ if INPUT_MISC ...@@ -15,7 +15,6 @@ if INPUT_MISC
config INPUT_PCSPKR config INPUT_PCSPKR
tristate "PC Speaker support" tristate "PC Speaker support"
depends on PCSPKR_PLATFORM depends on PCSPKR_PLATFORM
depends on SND_PCSP=n
help help
Say Y here if you want the standard PC Speaker to be used for Say Y here if you want the standard PC Speaker to be used for
bells and whistles. bells and whistles.
......
...@@ -589,6 +589,21 @@ static void atp_close(struct input_dev *input) ...@@ -589,6 +589,21 @@ static void atp_close(struct input_dev *input)
dev->open = 0; dev->open = 0;
} }
static int atp_handle_geyser(struct atp *dev)
{
struct usb_device *udev = dev->udev;
if (!atp_is_fountain(dev)) {
/* switch to raw sensor mode */
if (atp_geyser_init(udev))
return -EIO;
printk(KERN_INFO "appletouch: Geyser mode initialized.\n");
}
return 0;
}
static int atp_probe(struct usb_interface *iface, const struct usb_device_id *id) static int atp_probe(struct usb_interface *iface, const struct usb_device_id *id)
{ {
struct atp *dev; struct atp *dev;
...@@ -633,14 +648,6 @@ static int atp_probe(struct usb_interface *iface, const struct usb_device_id *id ...@@ -633,14 +648,6 @@ static int atp_probe(struct usb_interface *iface, const struct usb_device_id *id
else else
dev->datalen = 81; dev->datalen = 81;
if (!atp_is_fountain(dev)) {
/* switch to raw sensor mode */
if (atp_geyser_init(udev))
goto err_free_devs;
printk(KERN_INFO "appletouch: Geyser mode initialized.\n");
}
dev->urb = usb_alloc_urb(0, GFP_KERNEL); dev->urb = usb_alloc_urb(0, GFP_KERNEL);
if (!dev->urb) if (!dev->urb)
goto err_free_devs; goto err_free_devs;
...@@ -654,6 +661,10 @@ static int atp_probe(struct usb_interface *iface, const struct usb_device_id *id ...@@ -654,6 +661,10 @@ static int atp_probe(struct usb_interface *iface, const struct usb_device_id *id
usb_rcvintpipe(udev, int_in_endpointAddr), usb_rcvintpipe(udev, int_in_endpointAddr),
dev->data, dev->datalen, atp_complete, dev, 1); dev->data, dev->datalen, atp_complete, dev, 1);
error = atp_handle_geyser(dev);
if (error)
goto err_free_buffer;
usb_make_path(udev, dev->phys, sizeof(dev->phys)); usb_make_path(udev, dev->phys, sizeof(dev->phys));
strlcat(dev->phys, "/input0", sizeof(dev->phys)); strlcat(dev->phys, "/input0", sizeof(dev->phys));
...@@ -744,6 +755,20 @@ static void atp_disconnect(struct usb_interface *iface) ...@@ -744,6 +755,20 @@ static void atp_disconnect(struct usb_interface *iface)
printk(KERN_INFO "input: appletouch disconnected\n"); printk(KERN_INFO "input: appletouch disconnected\n");
} }
static int atp_recover(struct atp *dev)
{
int error;
error = atp_handle_geyser(dev);
if (error)
return error;
if (dev->open && usb_submit_urb(dev->urb, GFP_ATOMIC))
return -EIO;
return 0;
}
static int atp_suspend(struct usb_interface *iface, pm_message_t message) static int atp_suspend(struct usb_interface *iface, pm_message_t message)
{ {
struct atp *dev = usb_get_intfdata(iface); struct atp *dev = usb_get_intfdata(iface);
...@@ -764,12 +789,20 @@ static int atp_resume(struct usb_interface *iface) ...@@ -764,12 +789,20 @@ static int atp_resume(struct usb_interface *iface)
return 0; return 0;
} }
static int atp_reset_resume(struct usb_interface *iface)
{
struct atp *dev = usb_get_intfdata(iface);
return atp_recover(dev);
}
static struct usb_driver atp_driver = { static struct usb_driver atp_driver = {
.name = "appletouch", .name = "appletouch",
.probe = atp_probe, .probe = atp_probe,
.disconnect = atp_disconnect, .disconnect = atp_disconnect,
.suspend = atp_suspend, .suspend = atp_suspend,
.resume = atp_resume, .resume = atp_resume,
.reset_resume = atp_reset_resume,
.id_table = atp_table, .id_table = atp_table,
}; };
......
...@@ -192,6 +192,13 @@ static struct dmi_system_id __initdata i8042_dmi_nomux_table[] = { ...@@ -192,6 +192,13 @@ static struct dmi_system_id __initdata i8042_dmi_nomux_table[] = {
DMI_MATCH(DMI_PRODUCT_NAME, "AMILO Pro V2010"), DMI_MATCH(DMI_PRODUCT_NAME, "AMILO Pro V2010"),
}, },
}, },
{
.ident = "Fujitsu-Siemens Amilo Pro 2030",
.matches = {
DMI_MATCH(DMI_SYS_VENDOR, "FUJITSU SIEMENS"),
DMI_MATCH(DMI_PRODUCT_NAME, "AMILO PRO V2030"),
},
},
{ {
/* /*
* No data is coming from the touchscreen unless KBC * No data is coming from the touchscreen unless KBC
......
...@@ -952,8 +952,12 @@ static int i8042_resume(struct platform_device *dev) ...@@ -952,8 +952,12 @@ static int i8042_resume(struct platform_device *dev)
i8042_ctr |= I8042_CTR_AUXDIS | I8042_CTR_KBDDIS; i8042_ctr |= I8042_CTR_AUXDIS | I8042_CTR_KBDDIS;
i8042_ctr &= ~(I8042_CTR_AUXINT | I8042_CTR_KBDINT); i8042_ctr &= ~(I8042_CTR_AUXINT | I8042_CTR_KBDINT);
if (i8042_command(&i8042_ctr, I8042_CMD_CTL_WCTR)) { if (i8042_command(&i8042_ctr, I8042_CMD_CTL_WCTR)) {
printk(KERN_ERR "i8042: Can't write CTR to resume\n"); printk(KERN_WARNING "i8042: Can't write CTR to resume, retrying...\n");
return -EIO; msleep(50);
if (i8042_command(&i8042_ctr, I8042_CMD_CTL_WCTR)) {
printk(KERN_ERR "i8042: CTR write retry failed\n");
return -EIO;
}
} }
......
...@@ -47,6 +47,9 @@ static const struct usb_device_id usb_quirk_list[] = { ...@@ -47,6 +47,9 @@ static const struct usb_device_id usb_quirk_list[] = {
/* Edirol SD-20 */ /* Edirol SD-20 */
{ USB_DEVICE(0x0582, 0x0027), .driver_info = USB_QUIRK_RESET_RESUME }, { USB_DEVICE(0x0582, 0x0027), .driver_info = USB_QUIRK_RESET_RESUME },
/* appletouch */
{ USB_DEVICE(0x05ac, 0x021a), .driver_info = USB_QUIRK_RESET_RESUME },
/* Avision AV600U */ /* Avision AV600U */
{ USB_DEVICE(0x0638, 0x0a13), .driver_info = { USB_DEVICE(0x0638, 0x0a13), .driver_info =
USB_QUIRK_STRING_FETCH_255 }, USB_QUIRK_STRING_FETCH_255 },
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment