Message ID | 20121125212100.GE24024@elie.Belkin (mailing list archive) |
---|---|
State | Not Applicable, archived |
Headers | show |
Jonathan Nieder wrote: > Some USB MIDI keyboards fail to operate after a USB autosuspend. Make that *all* USB MIDI devices with input ports. This is not a bug in the device, but one of the many bugs introduced with the autosuspend code in <http://git.kernel.org/linus/88a8516a2128>. That patch does not handle input at all, i.e., when the driver wants to read from the device, it just doesn't take it out of suspend mode. > A workaround is to disable USB autosuspend for these devices by > putting AUTOSUSPEND_USBID_BLACKLIST="0763:2027" (resp. 0763:019b) in > /etc/laptop-mode/conf.d/usb-autosuspend.conf. In the spirit of commit > 166cb70e97bd ("usb: add USB_QUIRK_RESET_RESUME for M-Audio 88es"), > reset the device on resume so this workaround is not needed any more. It is not feasible to add the IDs of all USB MIDI devices. I'm working on a fix that adds proper power management for input ports, but this requires the driver to be reorganized a little ... Regards, Clemens -- To unsubscribe from this list: send the line "unsubscribe linux-pm" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/usb/core/quirks.c b/drivers/usb/core/quirks.c index fdefd9c7f7af..998c6a8290f6 100644 --- a/drivers/usb/core/quirks.c +++ b/drivers/usb/core/quirks.c @@ -105,6 +105,12 @@ static const struct usb_device_id usb_quirk_list[] = { /* Midiman M-Audio Keystation 88es */ { USB_DEVICE(0x0763, 0x0192), .driver_info = USB_QUIRK_RESET_RESUME }, + /* Midiman M-Audio KeyRig 49 */ + { USB_DEVICE(0x0763, 0x019b), .driver_info = USB_QUIRK_RESET_RESUME }, + + /* Midiman M-Audio Oxygen 49 */ + { USB_DEVICE(0x0763, 0x2027), .driver_info = USB_QUIRK_RESET_RESUME }, + /* M-Systems Flash Disk Pioneers */ { USB_DEVICE(0x08ec, 0x1000), .driver_info = USB_QUIRK_RESET_RESUME },
Some USB MIDI keyboards fail to operate after a USB autosuspend. The device is recognized by ALSA, but no events are received and the device goes quiet. $ amidi -l Dir Device Name IO hw:1,0,0 Oxygen 49 MIDI 1 $ amidi -p hw:1,0,0 -d <... play some notes ...> ^C 0 bytes read A workaround is to disable USB autosuspend for these devices by putting AUTOSUSPEND_USBID_BLACKLIST="0763:2027" (resp. 0763:019b) in /etc/laptop-mode/conf.d/usb-autosuspend.conf. In the spirit of commit 166cb70e97bd ("usb: add USB_QUIRK_RESET_RESUME for M-Audio 88es"), reset the device on resume so this workaround is not needed any more. Noticed on a kernel close to 3.2.10. Tested against 3.6.5. Debian's 2.6.32.54-based kernel did not seem to be affected, though it's not clear whether that is due to code or configuration. Addresses http://bugs.debian.org/664068 Reported-and-tested-by: David Banks <amoebae@gmail.com> # Oxygen 49 Reported-and-tested-by: Olivier MATZ <zer0@droids-corp.org> # KeyRig 49 Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Cc: stable@vger.kernel.org --- Thoughts? drivers/usb/core/quirks.c | 6 ++++++ 1 file changed, 6 insertions(+)