summaryrefslogtreecommitdiffstats
path: root/sound/usb/midi.c
Commit message (Collapse)AuthorAgeFilesLines
* ALSA: usb-audio: add MIDI port names for some Roland devicesClemens Ladisch2013-06-271-0/+33
| | | | Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
* ALSA: usb-audio: add support for many Roland/Yamaha devicesClemens Ladisch2013-06-271-0/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add quirks to detect the various vendor-specific descriptors used by Roland and Yamaha in most of their recent USB audio and MIDI devices. Together with the previous patch, this should add audio/MIDI support for the following USB devices: - Edirol motion dive .tokyo performance package - Roland MC-808 Synthesizer - Roland BK-7m Synthesizer - Roland VIMA JM-5/8 Synthesizer - Roland SP-555 Sequencer - Roland V-Synth GT Synthesizer - Roland Music Atelier AT-75/100/300/350C/500/800/900/900C Organ - Edirol V-Mixer M-200i/300/380/400/480/R-1000 - BOSS GT-10B Effects Processor - Roland Fantom G6/G7/G8 Keyboard - Cakewalk Sonar V-Studio 20/100/700 Audio Interface - Roland GW-8 Keyboard - Roland AX-Synth Keyboard - Roland JUNO-Di/STAGE/Gi Keyboard - Roland VB-99 Effects Processor - Cakewalk UM-2G MIDI Interface - Roland A-500S Keyboard - Roland SD-50 Synthesizer - Roland OCTAPAD SPD-30 Controller - Roland Lucina AX-09 Synthesizer - BOSS BR-800 Digital Recorder - Roland DUO/TRI-CAPTURE (EX) Audio Interface - BOSS RC-300 Loop Station - Roland JUPITER-50/80 Keyboard - Roland R-26 Recorder - Roland SPD-SX Controller - BOSS JS-10 Audio Player - Roland TD-11/15/30 Drum Module - Roland A-49/88 Keyboard - Roland INTEGRA-7 Synthesizer - Roland R-88 Recorder Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
* ALSA: usb-audio: disable autopm for MIDI devicesClemens Ladisch2013-04-151-11/+2Star
| | | | | | | | | | | | | | | | | | | | | | | | | | Commit 88a8516a2128 (ALSA: usbaudio: implement USB autosuspend) introduced autopm for all USB audio/MIDI devices. However, many MIDI devices, such as synthesizers, do not merely transmit MIDI messages but use their MIDI inputs to control other functions. With autopm, these devices would get powered down as soon as the last MIDI port device is closed on the host. Even some plain MIDI interfaces could get broken: they automatically send Active Sensing messages while powered up, but as soon as these messages cease, the receiving device would interpret this as an accidental disconnection. Commit f5f165418cab (ALSA: usb-audio: Fix missing autopm for MIDI input) introduced another regression: some devices (e.g. the Roland GAIA SH-01) are self-powered but do a reset whenever the USB interface's power state changes. To work around all this, just disable autopm for all USB MIDI devices. Reported-by: Laurens Holst Cc: <stable@vger.kernel.org> Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: usb-audio: neaten EXPORT_SYMBOLS placementEldad Zack2013-04-041-4/+3Star
| | | | | | | Put EXPORT_SYMBOLS directly under the exported function. Signed-off-by: Eldad Zack <eldad@fogrefinery.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: usb-audio: convert list_for_each to entry variantEldad Zack2013-04-041-3/+2Star
| | | | | | | | Change occurances of list_for_each into list_for_each_entry where applicable. Signed-off-by: Eldad Zack <eldad@fogrefinery.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: usb-audio: Fix kernel panic of Digidesign Mbox2 quirkDamien Zammit2013-01-041-4/+0Star
| | | | | | | | | | | | | | | This patch is based on 3.8-rc1. It fixes two things: 1) A kernel panic caused by incorrect allocation of a u8 variable "bootresponse". 2) A noisy dmesg (urb status -32) caused by broken pipe to an invalid midi endpoint. It is also a little cleaner because there is no need for a new QUIRK_MIDI type as suggested by kernel developers, since the device follows exactly the MIDIMAN protocol. Signed-off-by: Damien Zammit <damien@zamaudio.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: usb-audio: Support for Digidesign Mbox 2 USB sound card:Damien Zammit2012-12-191-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | This patch is the result of a lot of trial and error, since there are no specs available for the device. Full duplex support is provided, i.e. playback and recording in stereo. The format is hardcoded at 48000Hz @ 24 bit, which is the maximum that the device supports. Also, MIDI in and MIDI out both work. Users will notice that the S/PDIF light also flashes when playback or recording is active. I believe this means that S/PDIF input/output is simultaneously activated with the analogue i/o during use. But this particular functionality remains untested. Note that this particular version of the patch is so far untested on the physical hardware because I have not compiled a full kernel with the changes. However, extensive testing has been done by many users of the hardware who believe other versions of my patch have worked since circa 2009. [Modified to make a function static by tiwai] Signed-off-by: Damien Zammit <damien@zamaudio.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: usb-audio: Fix missing autopm for MIDI inputTakashi Iwai2012-12-041-42/+46
| | | | | | | | | | | | | | | | | | The commit [88a8516a: ALSA: usbaudio: implement USB autosuspend] added the support of autopm for USB MIDI output, but it didn't take the MIDI input into account. This patch adds the following for fixing the autopm: - Manage the URB start at the first MIDI input stream open, instead of the time of instance creation - Move autopm code to the common substream_open() - Make snd_usbmidi_input_start/_stop() more robust and add the running state check Reviewd-by: Clemens Ladisch <clemens@ladisch.de> Tested-by: Clemens Ladisch <clemens@ladisch.de> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: usb-audio: Avoid autopm calls after disconnectionTakashi Iwai2012-12-041-1/+22
| | | | | | | | | | | | | Add a similar protection against the disconnection race and the invalid use of usb instance after disconnection, as well as we've done for the USB audio PCM. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=51201 Reviewd-by: Clemens Ladisch <clemens@ladisch.de> Tested-by: Clemens Ladisch <clemens@ladisch.de> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: ua101, usx2y: fix broken MIDI outputClemens Ladisch2012-11-181-2/+6
| | | | | | | | | | | | | | | | | | | | | Commit 88a8516a2128 (ALSA: usbaudio: implement USB autosuspend) added autosuspend code to all files making up the snd-usb-audio driver. However, midi.c is part of snd-usb-lib and is also used by other drivers, not all of which support autosuspend. Thus, calls to usb_autopm_get_interface() could fail, and this unexpected error would result in the MIDI output being completely unusable. Make it work by ignoring the error that is expected with drivers that do not support autosuspend. Reported-by: Colin Fletcher <colin.m.fletcher@googlemail.com> Reported-by: Devin Venable <venable.devin@gmail.com> Reported-by: Dr Nick Bailey <nicholas.bailey@glasgow.ac.uk> Reported-by: Jannis Achstetter <jannis_achstetter@web.de> Reported-by: Rui Nuno Capela <rncbc@rncbc.org> Cc: Oliver Neukum <oliver@neukum.org> Cc: 2.6.39+ <stable@vger.kernel.org> Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
* sound: Add module.h to the previously silent sound usersPaul Gortmaker2011-11-011-0/+1
| | | | | | | | Lots of sound drivers were getting module.h via the implicit presence of it in <linux/device.h> but we are going to clean that up. So fix up those users now. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
* ALSA: usb-audio: add Starr Labs USB MIDI supportKristian Amlie2011-08-261-0/+27
| | | | | | | | | | | | Add support for Starr Labs USB MIDI devices such as the Z7S, which are based on an FTDI serial UART chip. Based on a patch by Daniel Mack. Signed-off-by: Kristian Amlie <kristian@amlie.name> Acked-by: Daniel Mack <zonque@gmail.com> Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: usb-audio: define another USB ID for a buggy USB MIDI cableTarek Soliman2011-04-061-0/+1
| | | | | | | | | | | There are many USB MIDI cables out there that have buggy firmware that reports it can do more than 4 bytes in a packet when they can only properly handle 4 This patch adds the ID of yet another one of those cables Signed-off-by: Tarek Soliman <tarek@bashasoliman.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: usbaudio: implement USB autosuspendOliver Neukum2011-03-111-0/+8
| | | | | | | | | | | | Devices are autosuspended if no pcm nor midi channel is open Mixer devices may be opened. This way they are active when in use to play or record sound, but can be suspended while users have a mixer application running. [Small clean-ups using static inline by tiwai] Signed-off-by: Oliver Neukum <oneukum@suse.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: snd-usb-us122l: Fix MIDI outputKarsten Wiese2011-01-111-2/+9
| | | | | | | | The US-122L always reads 9 bytes per urb unless they are set to 0xFD. Signed-off-by: Karsten Wiese <fzu@wemgehoertderstaat.de> Cc: stable@kernel.org Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: usb-audio: use enum control info helperClemens Ladisch2011-01-101-7/+1Star
| | | | | | | Simplify info callbacks by using the snd_ctl_enum_info() helper function. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: usb-audio: add Novation Launchpad supportClemens Ladisch2010-10-221-3/+4
| | | | | | | | | | | Add a quirk entry for the Novation Launchpad USB MIDI controller. QUIRK_MIDI_FASTLANE gets renamed to *_RAW_BYTES because this quirk type is now shared by different devices. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Tested-by: Jakob Flierl <jakob.flierl@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: usb: USB3 SuperSpeed sound supportPaul Zimmerman2010-08-141-1/+8
| | | | | | | | | | | | | | | | | | | This is V2 of the patch, after feedback from Clemens and Daniel. This patch adds SuperSpeed support to the USB drivers under sound/. It adds tests for USB_SPEED_SUPER to the appropriate places that check for the USB speed. This patch has been tested with our SS USB3 device emulating a set of Yamaha speakers and a Logitech microphone, but with the descriptors modified to add USB3 support. It has also been tested with the real speakers and microphone, to make sure that USB2 devices still work. Signed-off-by: Paul Zimmerman <paulz@synopsys.com> Cc: Clemens Ladisch <clemens@ladisch.de> Cc: Daniel Mack <daniel@caiaq.de> Cc: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* ALSA: usb-midi: whitespace fixesDaniel Mack2010-06-231-7/+7
| | | | | Signed-off-by: Daniel Mack <daniel@caiaq.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* Merge branch 'for-linus' of ↵Linus Torvalds2010-05-261-0/+110
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6 * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6: ALSA: emu10k1: allow high-resolution mixer controls ALSA: pcm: fix delta calculation at boundary wraparound ALSA: hda_intel: fix handling of non-completion stream interrupts ALSA: usb/caiaq: fix Traktor Kontrol X1 ABS_HAT2X axis ALSA: hda: Fix model quirk for Dell M1730 ALSA: hda - iMac9,1 sound fixes ALSA: hda: Use LPIB for Toshiba A100-259 ALSA: hda: Use LPIB for Acer Aspire 5110 ALSA: aw2-alsa.c: use pci_ids.h defines and fix checkpatch.pl noise ALSA: usb-audio: add support for Akai MPD16 ALSA: pcm: fix the fix of the runtime->boundary calculation
| * ALSA: usb-audio: add support for Akai MPD16Krzysztof Foltman2010-05-211-0/+110
| | | | | | | | | | | | | | | | | | The decoding/encoding is based on own reverse-engineering. Both control and data ports are handled. Writing to control port supports SysEx events only, as this is the only type of messages that MPD16 recognizes. Signed-off-by: Krzysztof Foltman <wdev@foltman.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
* | Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6Linus Torvalds2010-05-211-7/+7
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6: (229 commits) USB: remove unused usb_buffer_alloc and usb_buffer_free macros usb: musb: update gfp/slab.h includes USB: ftdi_sio: fix legacy SIO-device header USB: kl5usb105: reimplement using generic framework USB: kl5usb105: minor clean ups USB: kl5usb105: fix memory leak USB: io_ti: use kfifo to implement write buffering USB: io_ti: remove unsused private counter USB: ti_usb: use kfifo to implement write buffering USB: ir-usb: fix incorrect write-buffer length USB: aircable: fix incorrect write-buffer length USB: safe_serial: straighten out read processing USB: safe_serial: reimplement read using generic framework USB: safe_serial: reimplement write using generic framework usb-storage: always print quirks USB: usb-storage: trivial debug improvements USB: oti6858: use port write fifo USB: oti6858: use kfifo to implement write buffering USB: cypress_m8: use kfifo to implement write buffering USB: cypress_m8: remove unused drain define ... Fix up conflicts (due to usb_buffer_alloc/free renaming) in drivers/input/tablet/acecad.c drivers/input/tablet/kbtab.c drivers/input/tablet/wacom_sys.c drivers/media/video/gspca/gspca.c sound/usb/usbaudio.c
* Merge branch 'fix/misc' into topic/usbTakashi Iwai2010-04-101-6/+18
|
* ALSA: usb-audio: refactor codeDaniel Mack2010-03-051-0/+2069
Clean up the usb audio driver by factoring out a lot of functions to separate files. Code for procfs, quirks, urbs, format parsers etc all got a new home now. Moved almost all special quirk handling to quirks.c and introduced new generic functions to handle them, so the exceptions do not pollute the whole driver. Renamed usbaudio.c to card.c because this is what it actually does now. Renamed usbmidi.c to midi.c for namespace clarity. Removed more things from usbaudio.h. The non-standard drivers were adopted accordingly. Signed-off-by: Daniel Mack <daniel@caiaq.de> Cc: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>