summaryrefslogtreecommitdiff
path: root/sound/usb
AgeCommit message (Collapse)Author
2010-05-26Merge branch 'for-linus' of ↵Linus Torvalds
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
2010-05-25ALSA: usb/caiaq: fix Traktor Kontrol X1 ABS_HAT2X axisDaniel Mack
Signed-off-by: Daniel Mack <daniel@caiaq.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-05-21ALSA: usb-audio: add support for Akai MPD16Krzysztof Foltman
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>
2010-05-20Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6Linus Torvalds
* 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
2010-05-20sound: fixup for usb_buffer_alloc/free renameStephen Rothwell
This is needed before the USB merge. Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-05-20USB: rename usb_buffer_alloc() and usb_buffer_free() usersDaniel Mack
For more clearance what the functions actually do, usb_buffer_alloc() is renamed to usb_alloc_coherent() usb_buffer_free() is renamed to usb_free_coherent() They should only be used in code which really needs DMA coherency. All call sites have been changed accordingly, except for staging drivers. Signed-off-by: Daniel Mack <daniel@caiaq.de> Cc: Alan Stern <stern@rowland.harvard.edu> Cc: Pedro Ribeiro <pedrib@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-05-20Merge branch 'topic/usb' into for-linusTakashi Iwai
2010-05-11ALSA: sound/usb: add preliminary support for UAC2 interruptsDaniel Mack
For both UAC1 and UAC2, interrupt endpoint messages are now parsed with structs rather that with anonymous buffer array accesses. For UAC2, only CUR interrupt notifications are supported for now. snd_usb_mixer_status_complete() was renamed to snd_usb_mixer_interrupt(). Fixed one indentation flaw on the way. Signed-off-by: Daniel Mack <daniel@caiaq.de> Cc: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-05-08ALSA: sound/usb: fix UAC1 regressionDaniel Mack
Commit 23caaf19b ("ALSA: usb-mixer: Add support for Audio Class v2.0") broke support for Class1 devices due to two faulty changes. This patch fixes it. Signed-off-by: Daniel Mack <daniel@caiaq.de> Reported-and-Tested-by: The Source <thesourcehim@gmail.com> Cc: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-04-16ALSA: usb/mixer - use get_iface_desc() rather than direct structureJaroslav Kysela
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2010-04-16Merge branch 'topic/usb' of ↵Jaroslav Kysela
git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6 into devel
2010-04-16Merge branch 'fix/misc' into for-linusTakashi Iwai
2010-04-10Merge branch 'fix/misc' into topic/usbTakashi Iwai
2010-04-10ALSA: usb - Fix Oops after usb-midi disconnectionTakashi Iwai
usb-midi causes sometimes Oops at snd_usbmidi_output_drain() after disconnection. This is due to the access to the endpoints which have been already released at disconnection while the files are still alive. This patch fixes the problem by checking disconnection state at snd_usbmidi_output_drain() and by releasing urbs but keeping the endpoint instances until really all freed. Tested-by: Tvrtko Ursulin <tvrtko@ursulin.net> Cc: <stable@kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-30include cleanup: Update gfp.h and slab.h includes to prepare for breaking ↵Tejun Heo
implicit slab.h inclusion from percpu.h percpu.h is included by sched.h and module.h and thus ends up being included when building most .c files. percpu.h includes slab.h which in turn includes gfp.h making everything defined by the two files universally available and complicating inclusion dependencies. percpu.h -> slab.h dependency is about to be removed. Prepare for this change by updating users of gfp and slab facilities include those headers directly instead of assuming availability. As this conversion needs to touch large number of source files, the following script is used as the basis of conversion. http://userweb.kernel.org/~tj/misc/slabh-sweep.py The script does the followings. * Scan files for gfp and slab usages and update includes such that only the necessary includes are there. ie. if only gfp is used, gfp.h, if slab is used, slab.h. * When the script inserts a new include, it looks at the include blocks and try to put the new include such that its order conforms to its surrounding. It's put in the include block which contains core kernel includes, in the same order that the rest are ordered - alphabetical, Christmas tree, rev-Xmas-tree or at the end if there doesn't seem to be any matching order. * If the script can't find a place to put a new include (mostly because the file doesn't have fitting include block), it prints out an error message indicating which .h file needs to be added to the file. The conversion was done in the following steps. 1. The initial automatic conversion of all .c files updated slightly over 4000 files, deleting around 700 includes and adding ~480 gfp.h and ~3000 slab.h inclusions. The script emitted errors for ~400 files. 2. Each error was manually checked. Some didn't need the inclusion, some needed manual addition while adding it to implementation .h or embedding .c file was more appropriate for others. This step added inclusions to around 150 files. 3. The script was run again and the output was compared to the edits from #2 to make sure no file was left behind. 4. Several build tests were done and a couple of problems were fixed. e.g. lib/decompress_*.c used malloc/free() wrappers around slab APIs requiring slab.h to be added manually. 5. The script was run on all .h files but without automatically editing them as sprinkling gfp.h and slab.h inclusions around .h files could easily lead to inclusion dependency hell. Most gfp.h inclusion directives were ignored as stuff from gfp.h was usually wildly available and often used in preprocessor macros. Each slab.h inclusion directive was examined and added manually as necessary. 6. percpu.h was updated not to include slab.h. 7. Build test were done on the following configurations and failures were fixed. CONFIG_GCOV_KERNEL was turned off for all tests (as my distributed build env didn't work with gcov compiles) and a few more options had to be turned off depending on archs to make things build (like ipr on powerpc/64 which failed due to missing writeq). * x86 and x86_64 UP and SMP allmodconfig and a custom test config. * powerpc and powerpc64 SMP allmodconfig * sparc and sparc64 SMP allmodconfig * ia64 SMP allmodconfig * s390 SMP allmodconfig * alpha SMP allmodconfig * um on x86_64 SMP allmodconfig 8. percpu.h modifications were reverted so that it could be applied as a separate patch and serve as bisection point. Given the fact that I had only a couple of failures from tests on step 6, I'm fairly confident about the coverage of this conversion patch. If there is a breakage, it's likely to be something in one of the arch headers which should be easily discoverable easily on most builds of the specific arch. Signed-off-by: Tejun Heo <tj@kernel.org> Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
2010-03-29ALSA: usb - update gfp/slab.h includesTejun Heo
Implicit slab.h inclusion via percpu.h is about to go away. Make sure gfp.h or slab.h is included as necessary. Signed-off-by: Tejun Heo <tj@kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-29ALSA: usb pcm: use of kmalloc requires the include of slab.hStephen Rothwell
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-29ALSA: usb - use of kmalloc/kfree requires the include of slab.hStephen Rothwell
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-25ALSA: usbaudio: Add basic support for M-Audio Fast Track Ultra seriesFelix Homann
This adds basic support for M-Audio's Fast Track Ultra series of USB audio interfaces. It is a refactored version of the patch Clemens Ladisch posted some time ago. Neither playback nor capturing work properly at 44100 Hz (don't know why). The other sampling rates work properly. There's no support for the DSP mixer, yet. Signed-off-by: Felix Homann <fexpop@web.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-23Merge remote branch 'alsa/devel' into topic/usbTakashi Iwai
2010-03-23ALSA: ua101: remove experimental statusClemens Ladisch
Now that the EHCI driver copes with small iso packets without blowing up, take the snd-ua101 driver out of the alpha-test stage. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2010-03-22ALSA: usb: fix usb build error when PM is not enabledRandy Dunlap
Fix build errors when CONFIG_PM is not enabled: sound/usb/card.c:629: error: 'usb_audio_suspend' undeclared here (not in a function) sound/usb/card.c:630: error: 'usb_audio_resume' undeclared here (not in a function) Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-22Merge branch 'topic/misc' into topic/usbTakashi Iwai
2010-03-22ALSA: usb/caiaq: Add support for Traktor Kontrol X1Daniel Mack
This device does not have audio controllers and backlit buttons only. Input data is handled over a dedicated USB endpoint. All functions are supported by the driver now. Signed-off-by: Daniel Mack <daniel@caiaq.de> Cc: Dmitry Torokhov <dtor@mail.ru> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-12ALSA: usb-mixer: Add support for Audio Class v2.0Daniel Mack
USB Audio Class v2.0 compliant devices have different descriptors and a different way of setting/getting min/max/res/cur properties. This patch adds support for them. Signed-off-by: Daniel Mack <daniel@caiaq.de> Cc: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-12ALSA: usb-mixer: parse descriptors with structsDaniel Mack
Introduce a number of new structs for mixer, selector, feature and processing units and some static inline helpers to access fields which have dynamic offsets. Use them in mixer.c to parse the descriptors. This is necessary for the upcoming audio v2 parsers. Signed-off-by: Daniel Mack <daniel@caiaq.de> Cc: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-12ALSA: usbmixer: rename usbmixer.[ch] -> mixer.[ch]Daniel Mack
For clearer namespace, also rename usbmixer_maps.c -> mixer_maps.c Signed-off-by: Daniel Mack <daniel@caiaq.de> Cc: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-12ALSA: usb-mixer: factor out quirksDaniel Mack
Move all non-standard mixer controls and vendor-specific extensions to a separate file. Some structs need to be exported now. Signed-off-by: Daniel Mack <daniel@caiaq.de> Cc: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-12ALSA: usb-mixer: use defines from audio.hDaniel Mack
No need for the private enum. Signed-off-by: Daniel Mack <daniel@caiaq.de> Cc: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-12linux/usb/audio.h: split headerDaniel Mack
- Split the audio.h file in two to clearly denote the differences between the standards. - Add many more defines to audio-v2.h. Most of them are not currently used. - Replaced a magic value with a proper define Signed-off-by: Daniel Mack <daniel@caiaq.de> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Cc: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-05ALSA: usb-audio: add support for samplerate setting on v2 devicesDaniel Mack
Sample rate setting is done with a 4-byte long class request that addresses the interface. Signed-off-by: Daniel Mack <daniel@caiaq.de> Cc: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-05ALSA: usb-audio: support multiple formats with audio class v2 devicesClemens Ladisch
Change the parser to correctly handle v2 descriptors with multiple format bits set. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-05ALSA: usb-audio: use a format bitmask per alternate settingClemens Ladisch
In preparation for USB audio 2.0 support, change the audioformat structure so that it uses a bitmask to specify possible formats. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-05ALSA: usb-audio: rename substream format field to altset_idxClemens Ladisch
The snd_usb_substream::format field actually contains the index of the current alternate setting, so rename it to altset_idx to avoid confusion. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-05ALSA: usb-audio: refactor codeDaniel Mack
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>
2010-03-05ALSA: usb-audio: header file cleanupsDaniel Mack
Rename snd-usb-lib to snd-usbmidi-lib as MIDI functions are the only thing it actually contains. Introduce a new header file to only declare these functions. Introduced usbmixer.h for all functions exported by usbmixer.c. Signed-off-by: Daniel Mack <daniel@caiaq.de> Cc: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-05ALSA: usb-audio: move ua101 driverDaniel Mack
As part of the USB audio code cleanup, move the non-standard ua101 driver out of the way. Signed-off-by: Daniel Mack <daniel@caiaq.de> Cc: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-03ALSA: usbaudio - remove debug "SAMPLE BYTES" printk lineJaroslav Kysela
Signed-off-by: Jaroslav Kysela <perex@perex.cz> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-02ALSA: usbaudio: Fix wrong bitrate for Creative Creative VF0470 Live CamArseniy Lartsev
This patch works around misbehaviour of Creative Creative VF0470 Live Cam which reports 16 kHz sample rate for audio capture while actually producing 8 kHz stream. Signed-off-by: Arseniy Lartsev <arseniy@fizlesh.ru> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-02Merge remote branch 'alsa/devel' into topic/miscTakashi Iwai
Conflicts: sound/usb/usbaudio.c
2010-03-02ALSA: ua101: removing debugging codeClemens Ladisch
Remove some code that is no longer needed now that the relevant parts of the driver have been tested. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2010-03-02ALSA: sound/usb/caiaq/midi.h: Checkpatch cleanupAndrea Gelmini
sound/usb/caiaq/midi.h:6: ERROR: "foo* bar" should be "foo *bar" Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net> Acked-by: Daniel Mack <daniel@caiaq.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-03-01ALSA: ua101: add Edirol UA-1000 supportClemens Ladisch
Add support for the Edirol UA-1000 to the UA-101 driver. Both devices behave the same, so we just have to shuffle around some interface numbers and name strings. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2010-02-23ALSA: usbaudio: consolidate header filesDaniel Mack
Use the definitions from linux/usb/audio.h all over the ALSA USB audio driver and add some missing definitions there as well. Use the endpoint attribute macros from linux/usb/ch9 and remove the own things from sound/usb/usbaudio.h. Now things are also nicely prefixed which makes understanding the code easier. Signed-off-by: Daniel Mack <daniel@caiaq.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-02-23ALSA: usbmixer: bail out early when parsing audio class v2 descriptorsDaniel Mack
This is just a quick hack that needs to be removed once the new units defined by the audio class v2.0 standard are supported. However, it allows using these devices for now, without mixer support. Signed-off-by: Daniel Mack <daniel@caiaq.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-02-23ALSA: usbaudio: implement basic set of class v2.0 parserDaniel Mack
This adds a number of parsers for audio class v2.0. In particular, the following internals are different and now handled by the code: * the number of streaming interfaces is now reported by an interface association descriptor. The old approach using a proprietary descriptor is deprecated. * The number of channels per interface is now stored in the AS_GENERAL descriptor (used to be part of the FORMAT_TYPE descriptor). * The list of supported sample rates is no longer stored in a variable length appendix of the format_type descriptor but is retrieved from the device using a class specific GET_RANGE command. * Supported sample formats are now reported as 32bit bitmap rather than a fixed value. For now, this is worked around by choosing just one of them. * A devices needs to have at least one CLOCK_SOURCE descriptor which denotes a clockID that is needed im the class request command. * Many descriptors (format_type, ...) have changed their layout. Handle this by casting the descriptors to the appropriate structs. Signed-off-by: Daniel Mack <daniel@caiaq.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-02-23ALSA: usbaudio: introduce new types for audio class v2Daniel Mack
This patch adds some definitions for audio class v2. Unfortunately, the UNIT types PROCESSING_UNIT and EXTENSION_UNIT have different numerical representations in both standards, so there is need for a _V1 add-on now. usbmixer.c is changed accordingly. Signed-off-by: Daniel Mack <daniel@caiaq.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-02-23ALSA: usbaudio: parse USB descriptors with structsDaniel Mack
In preparation of support for v2.0 audio class, use the structs from linux/usb/audio.h and add some new ones to describe the fields that are actually parsed by the descriptor decoders. Also, factor out code from usb_create_streams(). This makes it easier to adopt the new iteration logic needed for v2.0. Signed-off-by: Daniel Mack <daniel@caiaq.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-02-22ALSA: usbaudio Mbox support, output onlyChris J Arges
Signed-off-by: Chris J Arges <christopherarges@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-02-17Merge branch 'fix/misc' into topic/miscTakashi Iwai
Conflicts: sound/pci/hda/patch_realtek.c