summaryrefslogtreecommitdiff
path: root/sound/firewire/tascam/tascam.c
diff options
context:
space:
mode:
authorTakashi Sakamoto <o-takashi@sakamocchi.jp>2015-10-01 13:02:17 (GMT)
committerTakashi Iwai <tiwai@suse.de>2015-10-02 16:17:04 (GMT)
commite5e0c3dd257bf34cf001e10422943f90437f0f1b (patch)
tree3a4dfafb1815f996d9bf0366c2f9b95353a09199 /sound/firewire/tascam/tascam.c
parente453df44f0d6574e99fae990c89a22c6ec6bbb62 (diff)
downloadlinux-e5e0c3dd257bf34cf001e10422943f90437f0f1b.tar.xz
ALSA: firewire-tascam: add hwdep interface
This commit adds hwdep interface so as the other IEEE 1394 sound devices has. This interface is designed for mixer/control applications. By using this interface, an application can get information about firewire node, can lock/unlock kernel streaming and can get notification at starting/stopping kernel streaming. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/firewire/tascam/tascam.c')
-rw-r--r--sound/firewire/tascam/tascam.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/sound/firewire/tascam/tascam.c b/sound/firewire/tascam/tascam.c
index bb4f706..ee2f498 100644
--- a/sound/firewire/tascam/tascam.c
+++ b/sound/firewire/tascam/tascam.c
@@ -110,6 +110,8 @@ static int snd_tscm_probe(struct fw_unit *unit,
tscm->spec = (const struct snd_tscm_spec *)entry->driver_data;
mutex_init(&tscm->mutex);
+ spin_lock_init(&tscm->lock);
+ init_waitqueue_head(&tscm->hwdep_wait);
err = check_name(tscm);
if (err < 0)
@@ -125,6 +127,10 @@ static int snd_tscm_probe(struct fw_unit *unit,
if (err < 0)
goto error;
+ err = snd_tscm_create_hwdep_device(tscm);
+ if (err < 0)
+ goto error;
+
err = snd_card_register(card);
if (err < 0)
goto error;