aboutsummaryrefslogtreecommitdiff
path: root/drivers/usb/gadget/u_audio.c
AgeCommit message (Collapse)Author
2009-09-23headers: utsname.h reduxAlexey Dobriyan
* remove asm/atomic.h inclusion from linux/utsname.h -- not needed after kref conversion * remove linux/utsname.h inclusion from files which do not need it NOTE: it looks like fs/binfmt_elf.c do not need utsname.h, however due to some personality stuff it _is_ needed -- cowardly leave ELF-related headers and files alone. Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-09-23USB: gadget: audio driver seg-fault fixRobin Callender
The included patch can be applied to the new usb gadget audio driver. It addresses a seg-fault in uncovered in g_audio.ko. The fault occurs in the function u_audio.c::gaudio_open_end_dev() when device /dev/snd/pcmC0D0c (FILE_PCM_CAPTURE) is not present. I suspect there may be similar problems with device /dev/snd/pcmC0D0p (FILE_PCM_PLAYBACK) handling also. I leave that for the developer(s), as I was unsure as to the side-effects of not calling playback_default_hw_params() in the initialization phase. Signed-off-by: Robin Callender <robin_callender@hotmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-06-15USB: gadget: add USB Audio Gadget driverBryan Wu
Funtions added: - setup all the USB audio class device descriptors - handle class specific setup request - receive data from USB host by ISO transfer - play audio data by ALSA sound card - open and setup playback PCM interface - set default playback PCM parameters - provide playback functions for USB audio driver - provide PCM parameters set/get functions Test on: - Host: Ubuntu 8.10, kernel 2.6.27 - Gadget: EZKIT-BF548 with ASoC AD1980 codec Todo: - add real Mute control code - add real Volume control code - maybe find another way to replace dynamic buffer handling with static buffer allocation - test on Windows system - provide control interface to handle mute/volume control - provide capture interface in the future - test on BF527, other USB device controler and other audio codec Signed-off-by: Bryan Wu <cooloney@kernel.org> Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>