]> git.karo-electronics.de Git - linux-beck.git/commit
[media] sound/usb: Use Media Controller API to share media resources
authorShuah Khan <shuahkh@osg.samsung.com>
Wed, 2 Mar 2016 16:50:31 +0000 (13:50 -0300)
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>
Thu, 3 Mar 2016 18:01:13 +0000 (15:01 -0300)
commitaebb2b89bff0fdeb4e7ddd73dcbccde1a0f27554
treeaad7f1862beb01250032ac02d46d1dac11ccaa18
parent6ede20f9683c55dac8281b63d80b5cc669640252
[media] sound/usb: Use Media Controller API to share media resources

Change ALSA driver to use Media Controller API to share media resources
with DVB and V4L2 drivers on a AU0828 media device. Media Controller
specific initialization is done after sound card is registered. ALSA
creates Media interface and entity function graph nodes for Control,
Mixer, PCM Playback, and PCM Capture devices.

snd_usb_hw_params() will call Media Controller enable source handler
interface to request the media resource. If resource request is
granted, it will release it from snd_usb_hw_free(). If resource is
busy, -EBUSY is returned.

Media specific cleanup is done in usb_audio_disconnect().

Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
sound/usb/Kconfig
sound/usb/Makefile
sound/usb/card.c
sound/usb/card.h
sound/usb/media.c [new file with mode: 0644]
sound/usb/media.h [new file with mode: 0644]
sound/usb/mixer.h
sound/usb/pcm.c
sound/usb/quirks-table.h
sound/usb/stream.c
sound/usb/usbaudio.h